AbilitiesMultiverseObject IdentifierValueIndexLibrary
[ First Topic | Previous Topic | Next Topic | Last Topic | Index | Library ]

Object Object

The Object Model
An object is a combination of data and code, encapsulated into a single entity. The data portion is divided into properties, which are storage places for information about the current state of the object. The code portion is divided into methods, the actual compiled executable code that manipulates property values as part of the object's management , such as creating and destroying memory space for the object at run-time. An object that has been created at run-time is called an instance.

Within an object-oriented model, an object must descend from a parent object. One object in the model, the root, has no parent, and is called TObject. All objects within the model can trace their ancestry back to TObject, which contains properties and methods necessary for basic participation in the model itself. An object, plus all its ancestor objects, specifies the class of an object.

By convention, object class names begin with the capital letter T, which stands for type, the reserved word used in PASCAL to declare an object in code. Properties and methods within objects are separated from the class name by a period, as in TObject.ClassName. All identifiers used with Delphi objects are case insensitive. For example, "CLASSNAME" is the same as "ClassName."

When an object descends from a parent, it inherits all properties and methods not specifically excluded from inheritance. At run-time, it is possible to treat multiple objects of different types as the same class by accessing properties and methods common to the objects through inheritance. This is called polymorphism, and it is the key strength of an object-oriented model. It means that for abstract operations, the exact type of an object, and therefore, its underlying memory structure, is unimportant. Such abstract code is written only once, simplifying code maintenance.

See Also See Also:


AbilitiesMultiverseObject IdentifierValueIndexLibrary
[ First Topic | Previous Topic | Next Topic | Last Topic | Index | Library ]


The MUDzilla Simulation System
Please e-mail us your comments and inquiries.
© 1994-2002 Myne Corporation

Myne Corporation