"Object" Standard Type
Object is the implied root class of the Elements class hierarchy, on all platforms and languages, and the direct or indirect ancestor of every other class (and, on .NET and Java, of all value types as well).
In C#, the object keyword can also be used to refer to this type.
Type Mapping
- On .NET,
Objectmaps to theSystem.ObjectFCL class. - On Cocoa,
Objectmaps to theFoundation.NSObjectclass provided by SDKs. - On Java,
Objectmaps to thejava.lang.ObjectJDK class. - On Island,
Objectis implemented in Island RTL asRemObjects.Elements.System.Object.
The Swift Base Library also reverse-defines NSObject as alias to Object for all platforms to make it easier to share code with Apple's Swift, which does not define Object as a usable base class.
Per-Object-Model Objects on Island.
On Island, an Object type is declared for each Object Model (where applicable).
| Short | Long | Real Type |
|---|---|---|
| IslandObject | RemObjects.Elements.System.Island.Object | RemObjects.Elements.System.Object |
| CocoaObject | RemObjects.Elements.System.Cocoa.Object | Foundation.NSObject |
| SwiftObject | RemObjects.Elements.System.Swift.Object | N/A |
| DelphiObject | RemObjects.Elements.System.Delphi.Object | Delphi.System.TObject |
The short form "Object" (and in C# the object keyword) will always refer to the one matching the Default object model set for the project. This is achieved by the compiler putting the RemObjects.Elements.System.<DefaultObjectModel> namespace in scope.