asOid

asOid(): Object;

The asOid method of the String primitive type returns an object reference based on the contents of the receiving string.

This method is the inverse of the Object class getOidStringForObject method.

The following example shows the use of the asOid method.

begin
    // inspect an instance of an object, in this case 2048.5
    '2048.5'.asOid.inspect;
end;

For details about returning an object reference based on the contents of the oid-like receiving string based on class numbers and a following optional lifetime indication, see the String primitive type asObject method.