IsA( ) method
- Last Updated: October 30, 2020
- 1 minute read
- OpenEdge
- Version 12.2
- Documentation
Returns TRUE if a class or interface represented
by the Progress.Lang.Class object or object type-name expression
passed to the method is in the hierarchy of the Progress.Lang.Class class
instance on which the method is called. Otherwise, the method returns FALSE.
The IsA( ) method supports the reflection
capabilities of the Progress.Lang.Class class.
Return type: LOGICAL
Access: PUBLIC
Applies to: Progress.Lang.Class class
Syntax
|
- object-reference
- An object reference to a
Progress.Lang.Classinstance that can represent a class or interface type. - object-type-name
- A CHARACTER expression that evaluates to a class or interface type name.
This method returns TRUE when the Progress.Lang.Class class instance on which the method is called represents a class type that:
- Is the
same class represented by the
Progress.Lang.Classobject or class type-name expression passed to the method. - Derives from (is a subclass of) the class represented by the
Progress.Lang.Classobject or class type-name expression passed to the method. - Implements the interface represented by the
Progress.Lang.Classobject or interface type-name expression passed to the method. The passed interface type can be a super interface in the hierarchy of an interface that is implemented by the class type represented by theProgress.Lang.Classclass on which the method is called.
In this example, the IsA( ) method
is used to determine if a "Customer" object is
within the hierarchy of a "Bar" class. Note that "Customer"
can represent either a class type or an interface type.
|