OCLOperators oclIsTypeOf
No edit summary
No edit summary
Line 15: Line 15:
|}
|}
[[Category:OCLOperators]]
[[Category:OCLOperators]]
[[Category:OCL General Operators]]

Revision as of 07:15, 14 April 2023

oclIsTypeOf( typespec : Class ) : Boolean

Returns true if the type of self is the same as typespec - otherwise, returns false. This operation allows users to check the exact class type of self.

Expression Result
anEmployee.oclIsTypeOf(Employee) true
anEmployee.oclIsTypeOf(Person) false
aCat.oclIsTypeOf(Person) false
This page was edited 98 days ago on 02/10/2024. What links here