default->notEmpty() implies default->isCompatibleWith(parameteredElement) OCL allowSubstitutable implies constrainingClassifier->notEmpty() OCL result = ownedTemplateSignature->notEmpty() OCL result = allOwnedElements->select(oclIsKindOf(ParameterableElement)) OCL result = p->oclIsKindOf(self.oclType) and self.type.conformsTo(p.oclAsType(TypedElement).type) OCL templatedElement.ownedElement->includesAll(parameter.parameteredElement - parameter.ownedParameteredElement) OCL operand->forAll (op | op.oclIsKindOf (LiteralString)) OCL if subExpression->notEmpty() then operand->isEmpty() else operand->notEmpty() OCL result = if subExpression->notEmpty() then subExpression->iterate(se; stringValue = ‘| stringValue.concat(se.stringValue())) else operand->iterate()(op; stringValue = ‘ | stringValue.concat(op.value)) OCL parameterSubstitution->forAll(b | template.parameter->includes(b.formal)) OCL template.parameter->forAll(p | parameterSubstitution->select(b | b.formal = p)->size() <= 1) OCL (isAttribute(self) and (templateParameterSubstitution->notEmpty()) implies (templateParameterSubstitution->forAll(ts | isAttribute(ts.formal))) OCL result = p->oclIsKindOf(self.oclType) and self.type.conformsTo(p.oclAsType(TypedElement).type) OCL result = oclAsType(TemplatableElement).isTemplate() or general->exists(g | g.isTemplate()) OCL if extendedSignature->isEmpty() then Set{} else extendedSignature.parameter endif OCL true OCL redefinee.isRedefinitionContextValid(self) OCL result = redefinee.oclIsKindOf(RedefineableTemplateSignature) OCL result = p->oclIsKindOf(self.oclType) OCL result = templateParameter->notEmpty() OCL actual->forAll(a | a.isCompatibleWith(formal.parameteredElement)) OCL self.generalization->isEmpty() and self.feature->isEmpty() OCL isAbstract OCL (self.represented->select(p | p->oclIsKindOf(InformationItem))->forAll(p | p.informationFlow.source->forAll(q | self.informationFlow.source->include(q)) and p.informationFlow.target->forAll(q | self.informationFlow.target->include(q)))) and (self.represented->forAll(p | p->oclIsKindOf(Class) or oclIsKindOf(Interface) or oclIsKindOf(InformationItem) or oclIsKindOf(Signal) or oclIsKindOf(Component))) OCL self.conveyed.represented->forAll(p | p->oclIsKindOf(Class) or oclIsKindOf(Interface) or oclIsKindOf(InformationItem) or oclIsKindOf(Signal) or oclIsKindOf(Component)) OCL true OCL (self.informationSource->forAll(p | p->oclIsKindOf(Actor) or oclIsKindOf(Node) or oclIsKindOf(UseCase) or oclIsKindOf(Artifact) or oclIsKindOf(Class) or oclIsKindOf(Component) or oclIsKindOf(Port) or oclIsKindOf(Property) or oclIsKindOf(Interface) or oclIsKindOf(Package) or oclIsKindOf(ActivityNode) or oclIsKindOf(ActivityPartition) or oclIsKindOf(InstanceSpecification))) and (self.informationTarget->forAll(p | p->oclIsKindOf(Actor) or oclIsKindOf(Node) or oclIsKindOf(UseCase) or oclIsKindOf(Artifact) or oclIsKindOf(Class) or oclIsKindOf(Component) or oclIsKindOf(Port) or oclIsKindOf(Property) or oclIsKindOf(Interface) or oclIsKindOf(Package) or oclIsKindOf(ActivityNode) or oclIsKindOf(ActivityPartition) or oclIsKindOf(InstanceSpecification))) OCL self.classifierBehavior->notEmpty() implies self.classifierBehavior.specification->isEmpty() OCL self.ownedParameters-> select(p | p.direction=#out or p.direction=#inout or p.direction=#return)->size() >= 1 OCL def: hasAllDataTypeAttributes(d : DataType) : Boolean = d.ownedAttribute->forAll(a | a.type.oclIsTypeOf(DataType) and hasAllDataTypeAttributes(a.type)) self.ownedParameters->forAll(p | p.type.notEmpty() and p.oclIsTypeOf(DataType) and hasAllDataTypeAttributes(p)) OCL self.behavior.notEmpty() implies self.behavior.ownedParameters->select(p | p.direction<>#return)->isEmpty() OCL self.behavior.notEmpty() implies self.behavior.ownedParameter->select(p | p.direction=#return)->size() = 1 OCL true OCL true OCL true OCL true OCL true OCL true OCL not self.isActive implies self.ownedReception.isEmpty() OCL not self.isQuery OCL if (event->size() = 2) then (firstEvent->size() = 2) else (firstEvent->size() = 0) OCL true OCL if (constrainedElement->size() =2) then (firstEvent->size() = 2) else (firstEvent->size() = 0) OCL (not self.class->isEmpty()) implies self.packagedElement->isEmpty() OCL true OCL result = if end->exists( role.oclIsKindOf(Port) and partWithPort->isEmpty() and not role.oclAsType(Port).isBehavior) then ConnectorKind::delegation else ConnectorKind::assembly endif OCL true OCL self.nestedClassifier->isEmpty() OCL result = let realizedInterfaces : Set(Interface) = RealizedInterfaces(self) , realizingClassifiers : Set(Classifier) = Set{self.realizingClassifier}->union(self.allParents().realizingClassifier), allRealizingClassifiers : Set(Classifier) = realizingClassifiers->union(realizingClassifiers.allParents()) , realizingClassifierInterfaces : Set(Interface) = allRealizingClassifiers->iterate(c; rci : Set(Interface) = Set{} | rci->union(RealizedInterfaces(c))) , ports : Set(Port) = self.ownedPort->union(allParents.oclAsType(Set(EncapsulatedClassifier)).ownedPort) , providedByPorts : Set(Interface) = ports.provided in realizedInterfaces->union(realizingClassifierInterfaces) ->union(providedByPorts)->asSet() OCL result = (classifier.clientDependency-> select(dependency|dependency.oclIsKindOf(Realization) and dependency.supplier.oclIsKindOf(Interface)))-> collect(dependency|dependency.client) OCL result = let usedInterfaces : Set(Interface) = UsedInterfaces(self), realizingClassifiers : Set(Classifier) = Set{self.realizingClassifier}->union(self.allParents().realizingClassifier), allRealizingClassifiers : Set(Classifier) = realizingClassifiers->union(realizingClassifiers.allParents()), realizingClassifierInterfaces : Set(Interface) = allRealizingClassifiers->iterate(c; rci : Set(Interface) = Set{} | rci->union(UsedInterfaces(c))), ports : Set(Port) = self.ownedPort->union(allParents.oclAsType(Set(EncapsulatedClassifier)).ownedPort), usedByPorts : Set(Interface) = ports.required in usedInterfaces->union(realizingClassifierInterfaces) ->union(usedByPorts)->asSet() OCL result = (classifier.supplierDependency-> select(dependency|dependency.oclIsKindOf(Usage) and dependency.supplier.oclIsKindOf(interface)))-> collect(dependency|dependency.supplier) OCL self.variable.isAccessibleBy(self) OCL self.result.type =self.variable.type and self.result.ordering = self.variable.ordering OCL self.variable.multiplicity.compatibleWith(self.result.multiplicity) OCL self.value -> notEmpty() implies self.value.type = self.variable.type OCL self.value.multiplicity.is(1,1) OCL if not self.variable.isOrdered or self.variable.isUnique or isRemoveDuplicates then self.removeAt -> isEmpty() and self.value -> notEmpty() else self.value -> isEmpty() and self.removeAt -> notEmpty() and self.removeAt.type = UnlimitedNatural and self.removeAt.lower() = 1 and self.removeAt.upper() = 1 endif OCL true OCL true OCL true OCL let insertAtPins : Collection = self.insertAt in if self.variable.ordering = #unordered then insertAtPins->size() = 0 else let insertAtPin : InputPin = insertAt->asSequence()->first() in insertAtPins->size() = 1 and insertAtPin.type = UnlimitedNatural and insertAtPin.multiplicity.is(1,1)) endif OCL self.value -> notEmpty() OCL true OCL trigger.event.oclIsKindOf(CallEvent) OCL isUnmarshall = true OCL replyToCallEvent.oclIsKindOf(CallEvent) OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL self.result.type = self.end.type OCL self.end.Association.oclIsKindOf(AssociationClass) OCL self.object.type = self.end.association OCL self.end.association.memberEnd->forall(e | not e.isStatic) OCL self.result.multiplicity.is(1,1) OCL self.end.association.notEmpty() OCL self.object.multiplicity.is(1,1) OCL self.value.multiplicity.is(1,1) OCL self.value.type = self.qualifier.type OCL self.LinkEndData.end->collect(qualifier)->includes(self.qualifier) OCL self.result.multiplicity.is(0,#null) OCL true OCL self.object.type = self.qualifier.associationEnd.association OCL self.result.multiplicity.is(1,1) OCL self.qualifier.multiplicity.is(1,1) OCL self.object.multiplicity.is(1,1) OCL self.qualifier.associationEnd.association.oclIsKindOf(AssociationClass) OCL self.qualifier.associationEnd->size() = 1 OCL self.result.type = self.qualifier.type OCL self.qualifier.associationEnd.association.memberEnd->forall(e | not e.isStatic) OCL self.value->excludesAll(self.qualifier.value) OCL self.qualifier->collect(qualifier) = self.end.qualifier OCL self.argument.multiplicity.is(1,1) OCL not self.newClassifier->exists(isAbstract = true) OCL self.argument.type->size() = 0 OCL self.object.multiplicity.is(1,1) OCL self.result.multiplicity.is(1,1) OCL self.object.type->isEmpty() OCL self.result.type = Boolean OCL self.result.type = self.association() OCL self.association().oclIsKindOf(Class) OCL self.result.multiplicity.is(1,1) OCL true OCL true OCL true OCL result = Integer.allInstances()->forAll(i : Integer | self.includesCardinality(i) implies other.includesCardinality(i)) OCL result = (lowerbound = self.lowerbound and upperbound = self.upperbound) OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL self.object.multiplicity.is(1,1) OCL self.association->exists(end.type = self.object.type) OCL true OCL true OCL self.structuralFeature.multiplicity.compatibleWith(self.result.multiplicity) OCL self.result.type = self.structuralFeature.type and self.result.ordering = self.structuralFeature.ordering OCL result->notEmpty() implies self.result.multiplicity.is(1,1) OCL result->notEmpty() implies self.result.type = self.object.type OCL let host : Classifier = self.context in self.structuralFeature.visibility = #public or host = self.structuralFeature.featuringClassifier.type or (self.structuralFeature.visibility = #protected and host.allSupertypes ->includes(self.structuralFeature.featuringClassifier.type))) OCL self.structuralFeature.isStatic = #false OCL self.object.lowerBound()=1 and self.object.upperBound()=1 OCL self.structuralFeature.featuringClassifier.oclAsType(Type)->includes(self.object.type) or self.structuralFeature.oclAsType(Property).opposite.type = self.object.type OCL self.structuralFeature.featuringClassifier->size() = 1 OCL true OCL self.first.type->size() = 0 and self.second.type->size() = 0 OCL self.first.multiplicity.is(1,1) and self.second.multiplicity.is(1,1) OCL true OCL true OCL self.input->asSet() = let ledpins : Set = self.endData->collect(value) in if self.oclIsKindOf(LinkEndCreationData) then ledpins->union(self.endData.oclAsType(LinkEndCreationData).insertAt) else ledpins OCL self.endData->forall(end.oclisKindOf(NavigableEnd) implies end.isStatic = #false OCL self.endData->collect(end) = self.association()->collect(connection)) OCL result = self.endData->asSequence().first().end.association OCL if not self.structuralFeature.isOrdered or self.structuralFeature.isUnique or isRemoveDuplicates then self.removeAt -> isEmpty() and self.value -> notEmpty() else self.value -> isEmpty() and self.removeAt -> notEmpty() and self.removeAt.type = UnlimitedNatural and self.removeAt.lower = 1 and self.removeAt.upper = 1 endif OCL self.result.multiplicity.is(1,1) OCL true OCL self.result.type = self.context OCL self.context->size() = 1 OCL let insertAtPins : Collection = self.insertAt in if self.structuralFeature.isOrdered = #false then insertAtPins->size() = 0 else let insertAtPin : InputPin= insertAt->asSequence()->first() in insertAtPins->size() = 1 and insertAtPin.type = UnlimitedNatural and insertAtPin.multiplicity.is(1,1)) endif OCL self.value -> notEmpty() OCL self.association().isAbstract = #false OCL self.value.multiplicity.is(1,1) OCL self.end.association->size() = 1 OCL self.value.type = self.end.type OCL self.LinkAction.oclIsKindOf(CreateLinkAction) OCL let insertAtPins : Collection = self.insertAt in if self.end.ordering = #unordered then insertAtPins->size() = 0 else let insertAtPin : InputPin = insertAts->asSequence()->first() in insertAtPins->size() = 1 and insertAtPin.type = UnlimitedNatural and insertAtPin.multiplicity.is(1,1)) endif OCL true OCL true OCL let openend : Property = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in self.result.type = openend.type and self.result.ordering = openend.ordering OCL let openend : Property = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in openend.multiplicity.compatibleWith(self.result.multiplicity) OCL let host : Classifier = self.context in let openend : Property = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in openend.visibility = #public or self.endData->exists(oed | not oed.end = openend and (host = oed.end.participant or (openend.visibility = #protected and host.allSupertypes->includes(oed.end.participant)))) OCL let openend : Property = self.endData->select(ed | ed.value->size() = 0)->asSequence()->first().end in openend.isNavigable() OCL self.endData->select(ed | ed.value->size() = 0)->size() = 1 OCL true OCL self.target.type->size() = 0 OCL self.target.multiplicity.is(1,1) OCL self.result.type = self.classifier OCL not self.classifier.oclIsKindOf(AssociationClass) OCL self.result.multiplicity.is(1,1) OCL not (self.classifier.isAbstract = #true) OCL self.value->notEmpty() implies self.value.type = self.structuralFeature.type OCL result->notEmpty() implies self.result.type = self.object.type OCL self.value.multiplicity.is(1,1) OCL result->notEmpty() implies self.result.multiplicity.is(1,1) OCL true OCL self.end.notEmpty() implies self.collaboration.notEmpty() OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL result = ConnectorEnd.allInstances()->select(e | e.role=self) OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL true OCL region->forAll (r | r.subvertex->forAll (v | v.oclIsKindOf(Psuedostate) implies ((v.kind <> #deepHistory) and (v.kind <> #shallowHistory))))) OCL region->forAll(r | r.transition->forAll(t | t.oclIsTypeOf(ProtocolTransition))) OCL (not context->isEmpty( )) and specification->isEmpty() OCL true OCL region->forAll(r | r.subvertex->forAll(v | v.oclIsKindOf(State) implies (v.entry->isEmpty() and v.exit->isEmpty() and v.doActivity->isEmpty()))) OCL container.belongsToPSM() OCL true OCL effect->isEmpty() OCL true OCL result = if not stateMachine->isEmpty() then oclIsTypeOf(ProtocolStateMachine) else if not state->isEmpty() then state.container.belongsToPSM () else false OCL conectionPoint->forAll (c | c.kind = #entryPoint or c.kind = #exitPoint) OCL context->notEmpty() implies not context.oclIsKindOf(Interface) OCL specification->notEmpty() implies (context->notEmpty() and specification->featuringClassifier->exists (c | c = context)) OCL specification->notEmpty() implies connectionPoint->isEmpty() OCL true OCL result = if (s2 = s1) then true else if (s2.container->isEmpty() or not s2.container.owner.oclIsKindOf(State)) then false else ancestor(s1, s2.container.owner.oclAsType(State)) endif endif OCL result = true OCL result = true OCL (self.kind = #fork) implies self.outgoing->forAll (t1, t2 | t1<>t2 implies (self.stateMachine.LCA(t1.target, t2.target).container.isOrthogonal)) OCL (self.kind = #initial) implies (self.outgoing.guard->isEmpty() and self.outgoing.trigger->isEmpty()) OCL (self.kind = #join) implies self.incoming->forAll (t1, t2 | t1<>t2 implies (self.stateMachine.LCA(t1.source, t2.source).container.isOrthogonal)) OCL (self.kind = #initial) implies (self.outgoing->size <= 1) OCL ((self.kind = #deepHistory) or (self.kind = #shallowHistory)) implies (self.outgoing->size <= 1) OCL (self.kind = #fork) implies ((self.incoming->size = 1) and (self.outgoing->size >= 2)) OCL (self.kind = #choice) implies ((self.incoming->size >= 1) and (self.outgoing->size >= 1)) OCL (self.kind = #junction) implies ((self.incoming->size >= 1) and (self.outgoing->size >= 1)) OCL (self.kind = #join) implies ((self.outgoing->size = 1) and (self.incoming->size >= 2)) OCL true OCL self.doActivity->isEmpty() OCL self.outgoing->size() = 0 OCL self.submachine->isEmpty() OCL self.region->size() = 0 OCL self.exit->isEmpty() OCL self.entry->isEmpty() OCL isComposite implies not isSubmachineState OCL connectionPoint->forAll(cp|cp.kind = #entry or cp.kind = #exit) OCL connectionPoint->notEmpty() implies isComoposite OCL isSubmachineState implies connection->notEmpty ( ) OCL self.isSubmachineState implies (self.connection->forAll (cp | cp.entry->forAll (p | p.statemachine = self.submachine) and cp.exit->forAll (p | p.statemachine = self.submachine))) OCL result = container.containingStateMachine() OCL result = region.notEmpty() OCL result = true OCL result = (region->size () > 1) OCL result = true OCL result = region.isEmpty() OCL result = submachine.notEmpty() OCL result = let sm = containingStateMachine() in if sm.context->isEmpty() or sm.general->notEmpty() then sm else sm.context endif OCL (kind = TransitionKind::internal) implies (source.oclIsKindOf (State) and source = target) OCL (kind = TransitionKind::external) implies not (source.oclIsKindOf(Pseudostate) and source.oclAsType(Pseudostate).kind = PseudostateKind::entryPoint) OCL source.oclIsKindOf(Pseudostate) and (source.kind <> #initial)) implies trigger->isEmpty() OCL (target.oclIsKindOf(Pseudostate) and target.kind = #join) implies (source.oclIsKindOf(State)) OCL (kind = TransitionKind::local) implies ((source.oclIsKindOf (State) and source.oclAsType(State).isComposite) or (source.oclIsKindOf (Pseudostate) and source.oclAsType(Pseudostate).kind = PseudostateKind::entryPoint)) OCL self.source.oclIsKindOf(Pseudostate) implies (self.source.oclAsType(Pseudostate).kind = #initial) implies (self.source.container = self.stateMachine.top) implies ((self.trigger->isEmpty) or (self.trigger.stereotype.name = 'create')) OCL (source.oclIsKindOf(Pseudostate) and source.kind = #fork) implies (target.oclIsKindOf(State)) OCL (source.oclIsKindOf(Pseudostate) and source.kind = #fork) implies (guard->isEmpty() and trigger->isEmpty()) OCL true OCL (target.oclIsKindOf(Pseudostate) and target.kind = #join) implies (guard->isEmpty() and trigger->isEmpty()) OCL result = container.containingStateMachine() OCL result = (redefinee.oclIsKindOf(Transition) and let trans: Transition = redefinee.oclAsType(Transition) in (source() = trans.source() and trigger() = tran.trigger()) OCL redefinee.isRedefinitionContextValid(self) OCL result = let sm = containingStateMachine() in if sm.context->isEmpty() or sm.general->notEmpty() then sm else sm.context endif OCL entry->notEmpty() implies entry->forAll(e | e.kind = #entryPoint) OCL exit->notEmpty() implies exit->forAll(e | e.kind = #exitPoint) OCL (stateMachine->notEmpty() implies state->isEmpty()) and (state->notEmpty() implies stateMachine->isEmpty()) OCL self.subvertex->select (v | v.oclIsKindOf(Pseudostate))-> select(p : Pseudostate | p.kind = #initial)->size() <= 1 OCL self.subvertex->select(v | v.oclIsKindOf(Pseudostate))-> select(p : Pseudostate | p.kind = #shallowHistory)->size() <= 1 OCL self.subvertex->select (v | v.oclIsKindOf(Pseudostate))-> select(p : Pseudostate | p.kind = #deepHistory)->size() <= 1 OCL result = if stateMachine->isEmpty() then state.containingStateMachine() else stateMachine endif OCL result = true OCL result = true OCL result = let sm = containingStateMachine() in if sm.context->isEmpty() or sm.general->notEmpty() then sm else sm.context endif OCL result = if not container->isEmpty() then -- the container is a region container.containingStateMachine() else if (oclIsKindOf(Pseudostate)) then -- entry or exit point? if (kind = #entryPoint) or (kind = #exitPoint) then stateMachine else if (oclIsKindOf(ConnectionPointReference)) then state.containingStateMachine() -- no other valid cases possible endif OCL result = Transition.allInstances()->select(t | t.target=self) OCL result = Transition.allInstances()->select(t | t.source=self) OCL true OCL generalization->collect(g | g.general)->asSet()->size() <= 1 OCL true OCL true OCL true OCL true OCL not constrainedElement->includes(self) OCL not self.allOwnedElements()->includes(self) OCL self.mustBeOwned() implies owner->notEmpty() OCL result = ownedElement->union(ownedElement->collect(e | e.allOwnedElements())) OCL result = true OCL result = Set{} OCL result = Set{} OCL result = false OCL result = false OCL result = Set{} OCL result = Set{} OCL true OCL isDerivedUnion implies isReadOnly OCL self.subsettedProperty->notEmpty() implies (self.subsettingContext()->notEmpty() and self.subsettingContext()->forAll (sc | self.subsettedProperty->forAll(sp | sp.subsettingContext()->exists(c | sc.conformsTo(c))))) OCL isDerivedUnion implies isDerived OCL isComposite implies (upperBound()->isEmpty() or upperBound() <= 1) OCL self.subsettedProperty->forAll(sp | self.type.conformsTo(sp.type) and ((self.upperBound()->notEmpty() and sp.upperBound()->notEmpty()) implies self.upperBound()<=sp.upperBound() )) OCL if (redefinedProperty->notEmpty()) then (redefinitionContext->notEmpty() and redefinedProperty->forAll(rp| ((redefinitionContext->collect(fc| fc.allParents()))->asSet())->collect(c| c.allFeatures())->asSet()->includes(rp)) OCL true OCL result = Classifier.allInstances->exists(c | c.attribute->includes(p)) OCL result = (self.aggregation = #composite) OCL redefinee.isRedefinitionContextValid(self) OCL result = redefinee.oclIsKindOf(Property) and let prop : Property = redefinee.oclAsType(Property) in (prop.type.conformsTo(self.type) and ((prop.lowerBound()->notEmpty() and self.lowerBound()->notEmpty()) implies prop.lowerBound() >= self.lowerBound()) and ((prop.upperBound()->notEmpty() and self.upperBound()->notEmpty()) implies prop.lowerBound() <= self.lowerBound()) and (self.isComposite implies prop.isComposite)) OCL result = not classifier->isEmpty() or association.owningAssociation.navigableOwnedEnd->includes(self) OCL result = if owningAssociation->isEmpty() and association.memberEnd->size() = 2 then let otherEnd = (association.memberEnd - self)->any() in if otherEnd.owningAssociation->isEmpty() then otherEnd else Set{} endif else Set {} endif OCL result = if association->notEmpty() then association.endType-type else if classifier->notEmpty() then Set{classifier} else Set{} endif endif OCL slot->forAll(s | classifier->exists (c | c.allFeatures()->includes (s.definingFeature))) OCL classifier->forAll(c | (c.allFeatures()->forAll(f | slot->select(s | s.definingFeature = f)->size() <= 1))) OCL membersAreDistinguishable() OCL