Objects

Objects are instances of classes. All transient objects exist without a hierarchy in the data area of an internal mode. This means that objects can only be accessed within an internal mode. There are no memory areas for cross-transaction objects on the application server. Persistent objects on the database are in preparation but are not yet available. Any number of objects or instances can exist for a class. Each object has a unique identity and its own attributes.

Creating Objects

If you want to create an object, you need an object reference variable that can point to the desired class.

Access to Instance Components

A program can access the visible instance components of an object only through references in reference variables. For the syntax, see Accessing Components of Classes.

Lifetime of Objects

An object exists as long as it is used in the program. A program uses an object as long as at least one reference points to that object or at least one method of the object is registered as an event handler.

As soon as there is no longer a reference to the object and no method is registered any longer as an event handler, the object can be deleted by automatic storage management (garbage collection). This releases the identity of the object which can then be assigned to a new object.