Call 1800-123-2003
WHY ARE OBJECTS SAID TO BE INSTANCES OF A CLASS? |
| An object is a location in memory having a value and referenced by an identifier. An object can be a variable, function, or data structure. With the later introduction of object-oriented programming the same word, "object," refers to a particular instance of a class. Objects in "object-oriented programming" are essentially data structures together with their associated processing routines. For instance, a file is an object: a collection of data and the associated read and write routines. Objects are considered instances of classes. In common speech one refers to a file as a class, while the file is the object. A class defines properties and behaviour once, usually for multiple instantiations. |