filmov
tv
Attributes and Methods in Python | Public / Protected / Private (Mangling) | Techmaima

Показать описание
Attributes and Methods in Python | Public / Protected / Private | Techmaima
Description:
Attributes: 3 types are available
1) Public attribute - we can access from anywhere
2) _protected - we can access within the class and outside the class as well
* its indicating that don't use this since its protected ( _ will be there before the attribute name)
3) __Private attribute - you cant access outside the class since its private attribute (__ will be there before the attribute )
* by doing mangling you can access the Private attribute only outside the class
* within the class you can access easily
Methods: 3 types ( same as attributed ) - public - protected - private
* using mangling concept you can access the __ private attributes
#pythoncourse
#pythonforbeginners
#pythonattributes
#pythonmethods #publicattribute #protectedattribute #privateattribute #publicmethods #methdosinpython #privatemethod #protectedmethod #mangling #whatismangling #classattribute #pythoncodes #pythonexamples #pythonfullcourse #pythonvids #objectsinpython #instanceattributes #typesofmethodsinpython #typesofattributesinpython #pythoncompletecourse #pythondemo
Description:
Attributes: 3 types are available
1) Public attribute - we can access from anywhere
2) _protected - we can access within the class and outside the class as well
* its indicating that don't use this since its protected ( _ will be there before the attribute name)
3) __Private attribute - you cant access outside the class since its private attribute (__ will be there before the attribute )
* by doing mangling you can access the Private attribute only outside the class
* within the class you can access easily
Methods: 3 types ( same as attributed ) - public - protected - private
* using mangling concept you can access the __ private attributes
#pythoncourse
#pythonforbeginners
#pythonattributes
#pythonmethods #publicattribute #protectedattribute #privateattribute #publicmethods #methdosinpython #privatemethod #protectedmethod #mangling #whatismangling #classattribute #pythoncodes #pythonexamples #pythonfullcourse #pythonvids #objectsinpython #instanceattributes #typesofmethodsinpython #typesofattributesinpython #pythoncompletecourse #pythondemo