Member of class - Object Oriented Programming
Definitions Of Object: An object is combination and collection of data and code designed to emulate a physical abstract enmity.You can create number object of class. The properties, Variable and Methods define in class are called Members of class.
- Private Member Of Class: Private member of a class have strict access control Only the member function of same class can access this members.
- Protected Member of Class: A Protected member is accessible to member of its own calls and to any of the class member in a derived class.
- Public Member Of Class: A public member of class can be accessible from any where.
- Public and Private Static Member Of a Class: The static member of a class can be access without creating a object of class. While to access other member of class you have to create a object of class. The public static member can be accessed using access specifier while private static member can be accessed only the member functions.
- A private member is accessible only to members of the class in which private member is declared. They cannot be inherited
- A private member of the base class can be accessed in the derived class through the member of the base class.
- A protected member is accessible by member of its own class and to any of the class member in a derived class.