AbilitiesIndexItemValueIndexLibrary
[ First Topic | Previous Topic | Next Topic | Last Topic | Index | Library ]

Instance Instance

The Object Model
An instance is an object at run-time. Where objects and classes serve as blueprints, an instance represents the actual building. An instance is created when the object's constructor is invoked. This process allocates memory for the object's properties and methods, and initializes the instance to a base state. To destroy an object instance, the object's destructor method is called, upon which the object's allocated memory is returned to the operating system.

Normally, any property values defined during the lifetime of an instance are lost when the object is destroyed. Within MUDzilla, certain property values are stored within the fields of database tables such that their property values are preserved between instances of the object, and are called persistent properties.

It should be noted that an object's method code is loaded into memory only if no other object of the same class is currently present in memory. When an object's methods are initialized during construction, pointers to this code are recorded within the instance. When the last object of a given class is destroyed, the method code for that object is then removed from memory.

See Also See Also:


AbilitiesIndexItemValueIndexLibrary
[ 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