🚀 Welcome to MDriven Learn –  MDriven is now on Discord!  Don’t miss the latest Release Notes.
OCLOperators allSuperTypes
Created by Alexandra on 2017-08-13 · Last edited by Colline.ssali on 2025-12-29.


The allSuperTypes operator is a meta-model (type) operation that returns a collection of all parent (super) types of a given class. This includes both direct and indirect superclasses in the inheritance hierarchy. It is mainly used for model introspection, allowing you to analyze or validate class inheritance structures rather than instance data.

Meta information on all the super classes – in the inheritance order of the class.

ReturnType:

Collection(System.String)

Example:

Example showing OCLoperator allSuperTypes
Mango.allSuperTypes

Returns

['SysSuperClass', 'Fruit']


Mango.superTypes

Returns

['Fruit']

See also: