Previous Table of Contents Next


7.5 OCL Representation of Record Constraints

   [C-1] The owner of a Field and the type of a Field may not refer to the same Classifier instance.context Field inv:self.owner <> self.type

   [C-2] The scale attribute is valid only if the precision attribute is specified.context Field inv:self.scale->notEmpty implies self.precision->notEmpty

   [C-3] The precision attribute is valid only if the length attribute is not specified.context Field inv:self.precision->notEmpty implies self.length->isEmpty