how to find the children of a given classifier

how to find the children of a given classifier

From: Gonzalo Génova <>
Date: Wed, 22 Apr 2009 12:25:48 +0200
Message-ID: <>
 Dear all,

In UML 2.1.1 it is easy to find the parent(s) of a given classifier. See in
figure 7.9 the meta-associations between Classifier and Generalization and
in pp. 54-56 (metaclass Classifier) the first Constraint and the second
Additional Operation. All this results in self.parents( ) =

On the contrary, there is no direct way to find a classifier's children,
since one of the above mentioned meta-associations is one-way. Therefore, it
seems to me one needs to query all classes in the model, somewhat like this:

given a parent class p
for all classes c in the model
find those classes for which c.parents( ) includes p

My question is, how is this operation expressed in OCL?

Thank you very much,

Gonzalo Génova
Associate Professor
Department of Computer Science
Carlos III University of Madrid ** <>

Escuela Politécnica Superior
Avda. de la Universidad, 30
28911 Leganés - Madrid - Spain
Tel. (34) 91 624 91 07
Fax (34) 91 624 91 29
Received on Wed 22 Apr 2009 - 11:25:55 BST