object-oriented programming

(OOP) The basic concept in this approach is that of an "object" which is a data structure (abstract data type) encapsulated with a set of routines, called "methods" which operate on the data. Operations on the data can only be performed via these methods, which are common to all objects which are instances of a particular "class" (see inheritance). Thus the interface to objects is well defined, and allows the code implementing the methods to be changed so long as the interface remains the same.

Each class is a separate module and has a position in a "class hierarchy". Methods or code in one class can be passed down the hierarchy to a subclass or inherited from a superclass.

Procedure calls are described in term of message passing. A message names a method and may optionally include other arguments. When a message is sent to an object, the method is looked up in the object's class to find out how to perform that operation on the given object. If the method is not defined for the object's class, it is looked for in its superclass and so on up the class hierarchy until it is found or there is no higher superclass. Procedure calls always return a result object, which may be an error, as in the case where no superclass defines the requested method.

OOP started with SIMULA-67 around 1970. Popular examples of object-oriented languages are Smalltalk, from Xerox's Palo Alto Research Center (PARC) and C++. Others include Object Pascal, Objective C, DRAGOON, BETA, Emerald, POOL, Eiffel, Self, Oblog, ESP, POLKA and Loops.

MORE. MORE.

FAQ

Usenet newsgroup: comp.object.

(10 Feb 1995)