Modern programming languages make differences between any type definition and declaration of variables of that type. In object-oriented languages, a class definition is used for the purposes to create instances (objects) of this class.
A class definition consists of an encapsulated representation or state, and a collection of messages (methods or procedures) that can be sent to objects or instances of that class. Encapsulating is a technical name for information hiding. Encapsulation means that a user sees only the services available from an object but not how those services are implemented.
|