OCLOperators oclAsType
This page was created by Alexandra on 2017-08-13. Last edited by 62.169.16.147 on 2026-09-12.
oclAsType ( typespec : Class ) : T[edit source]
Returns self statically typed as typespec - if it is an instance of this type.
NOTE: This does not alter the runtime value of self - it only enables access to subtype operations. This operation allows users to cast self to another type.
| Expression | Result |
|---|---|
| aPerson.oclAsType(Employee) | an object of Employee type |
