PreviousNextIndex

CAST function

Returns a new object reference to the same class instance as an existing object reference, but with a different data type. This different data type is cast from the object type of the original object reference according to another specified object type. The two object types must be related, where one is a class type and the other is a subclass of that class type or where one is an interface type and the other is a class that implements the interface of that type.

When you cast an object reference, ABL treats it as if it referenced an instance of the object type to which it is cast. The underlying class hierarchy of the object instance does not change.

Syntax

CAST( object-reference, object-type-name ). 

object-reference
object-type-name
Notes
See also

DYNAMIC-CAST function, Type-name syntax, USING statement


OpenEdge Release 10.2B
Copyright © 2009 Progress Software Corporation
PreviousNextIndex