Commit 454b5c88 authored by Martti Käärik's avatar Martti Käärik
Browse files

Extension meta-models updated with tuple-format invariants.

parent 4240f27e
Loading
Loading
Loading
Loading
Loading
+3 −6
Changes for plugins/org.etsi.mts.tdl.model/model/configurations.ecore: 3 added lines, 6 removed lines.
Original line number Diff line number Diff line
@@ -36,10 +36,8 @@
      <details key="constraints" value="NoSelfMerge ComponentMergeType"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="NoSelfMerge" value="not (self.component.component = self.target.component and&#xA;self.component.configuration = self.target.configuration)"/>
      <details key="NoSelfMerge$message" value="'A \'ComponentInstance\' shall not be merged with itself, i.e. the source and target \'ComponentInstance\'s specified by means of the \'ComponentReference\'s shall be different. ' + self.toString()"/>
      <details key="ComponentMergeType" value="self.target.component.type.conformsTo(self.component.component.type)"/>
      <details key="ComponentMergeType$message" value="'The \'ComponentInstance\' specified by means of the target \'ComponentReference\'s shall have a \'ComponentType\' which conforms to the \'ComponentType\' of the source \'ComponentReference\'. ' + self.toString()"/>
      <details key="NoSelfMerge" value="Tuple { message : String = 'A \'ComponentInstance\' shall not be merged with itself, i.e. the source and target \'ComponentInstance\'s specified by means of the \'ComponentReference\'s shall be different. ' + self.toString(), status : Boolean = not (self.component.component = self.target.component and&#xA;self.component.configuration = self.target.configuration)&#xA;}.status"/>
      <details key="ComponentMergeType" value="Tuple { message : String = 'The \'ComponentInstance\' specified by means of the target \'ComponentReference\'s shall have a \'ComponentType\' which conforms to the \'ComponentType\' of the source \'ComponentReference\'. ' + self.toString(), status : Boolean = self.target.component.type.conformsTo(self.component.component.type)&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="target" lowerBound="1"
        eType="#//ComponentReference" containment="true"/>
@@ -53,8 +51,7 @@
      <details key="constraints" value="AliasMandatoryName"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="AliasMandatoryName" value="not self.name.oclIsUndefined() and self.name.size() > 0"/>
      <details key="AliasMandatoryName$message" value="'The \'name\' property of the \'ComponentAlias\' shall be set and it shall not be an empty String.' + self.toString()"/>
      <details key="AliasMandatoryName" value="Tuple { message : String = 'The \'name\' property of the \'ComponentAlias\' shall be set and it shall not be an empty String.' + self.toString(), status : Boolean = not self.name.oclIsUndefined() and self.name.size() > 0&#xA;}.status"/>
    </eAnnotations>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="ExtendedGateReference" eSuperTypes="tdl.ecore#//GateReference">
+14 −28
Changes for plugins/org.etsi.mts.tdl.model/model/structured.ecore: 14 added lines, 28 removed lines.
Original line number Diff line number Diff line
@@ -81,8 +81,7 @@
      <details key="constraints" value="MultiplePICS"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="MultiplePICS" value="self.getTestObjective().picsReference->size() &lt; 2&#xA;or self.getTestObjective().picsReference->forAll(p |&#xA;self.getTestObjective().picsReference->at(1) = p&#xA;or (not p.comment->isEmpty()&#xA;and (p.comment->first()._'body' = 'and'&#xA;or p.comment->first()._'body' = 'or')))"/>
      <details key="MultiplePICS$message" value="'A \'Comment\' with body containing an \'and\' or \'or\' shall be attached to the \'PICSReference\' as a Boolean operand if there are two or more \'PICSReference\'s and it is not the first \'PICSReference\'.' + self.toString()"/>
      <details key="MultiplePICS" value="Tuple { message : String = 'A \'Comment\' with body containing an \'and\' or \'or\' shall be attached to the \'PICSReference\' as a Boolean operand if there are two or more \'PICSReference\'s and it is not the first \'PICSReference\'.' + self.toString(), status : Boolean = self.getTestObjective().picsReference->size() &lt; 2&#xA;or self.getTestObjective().picsReference->forAll(p |&#xA;self.getTestObjective().picsReference->at(1) = p&#xA;or (not p.comment->isEmpty()&#xA;and (p.comment->first()._'body' = 'and'&#xA;or p.comment->first()._'body' = 'or')))&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="pics" lowerBound="1" eType="#//PICS"/>
  </eClassifiers>
@@ -104,8 +103,7 @@
      <details key="constraints" value="EntityOrComponentInstance"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="EntityOrComponentInstance" value="(not self.entity.oclIsUndefined() and self.component.oclIsUndefined())&#xA;or (self.entity.oclIsUndefined() and not self.component.oclIsUndefined())"/>
      <details key="EntityOrComponentInstance$message" value="'There shall be a reference to an \'Entity\' or a \'ComponentInstance\' but not both.' + self.toString()"/>
      <details key="EntityOrComponentInstance" value="Tuple { message : String = 'There shall be a reference to an \'Entity\' or a \'ComponentInstance\' but not both.' + self.toString(), status : Boolean = (not self.entity.oclIsUndefined() and self.component.oclIsUndefined())&#xA;or (self.entity.oclIsUndefined() and not self.component.oclIsUndefined())&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="entity" eType="#//Entity"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="component" eType="ecore:EClass tdl.ecore#//ComponentInstance"/>
@@ -119,10 +117,8 @@
      <details key="constraints" value="DataReferenceContents CompatibleDataTypeInDataReference"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="DataReferenceContents" value="self.content.isEffectivelyStatic()&#xA;and self.content.argument->forAll(a | a.dataUse.isEffectivelyStatic())&#xA;and self.content.argument->closure(a |&#xA;a.dataUse.argument)->forAll(a|a.dataUse.isEffectivelyStatic())"/>
      <details key="DataReferenceContents$message" value="'Only effectively static \'DataUse\'s may be used directly or indirectly in \'ParameterBinding\'s of the \'DataUse\' within a \'DataReference\'.' + self.toString()"/>
      <details key="CompatibleDataTypeInDataReference" value="self.container().oclIsTypeOf(EventOccurrenceSpecification) implies (&#xA;self.container().oclAsType(EventOccurrenceSpecification).oppositeEntityReference&#xA;->including(self.container().oclAsType(EventOccurrenceSpecification).entityReference)&#xA;->collect(e | e.component)->excluding(null)->isEmpty()&#xA;or&#xA;self.container().oclAsType(EventOccurrenceSpecification).oppositeEntityReference&#xA;->including(self.container().oclAsType(EventOccurrenceSpecification).entityReference)&#xA;->collect(e | e.component)->excluding(null)&#xA;->collect(c | c.type.allGates())&#xA;->collect(g | g.type.allDataTypes())&#xA;->exists(d | self.content.resolveDataType().conformsTo(d))&#xA;)"/>
      <details key="CompatibleDataTypeInDataReference$message" value="'Only compatible \'DataType\'s may be used directly when \'ComponentInstance\'s are referenced within a top-level \'DataReference\'.' + self.toString()"/>
      <details key="DataReferenceContents" value="Tuple { message : String = 'Only effectively static \'DataUse\'s may be used directly or indirectly in \'ParameterBinding\'s of the \'DataUse\' within a \'DataReference\'.' + self.toString(), status : Boolean = self.content.isEffectivelyStatic()&#xA;and self.content.argument->forAll(a | a.dataUse.isEffectivelyStatic())&#xA;and self.content.argument->closure(a |&#xA;a.dataUse.argument)->forAll(a|a.dataUse.isEffectivelyStatic())&#xA;}.status"/>
      <details key="CompatibleDataTypeInDataReference" value="Tuple { message : String = 'Only compatible \'DataType\'s may be used directly when \'ComponentInstance\'s are referenced within a top-level \'DataReference\'.' + self.toString(), status : Boolean = self.container().oclIsTypeOf(EventOccurrenceSpecification) implies (&#xA;self.container().oclAsType(EventOccurrenceSpecification).oppositeEntityReference&#xA;->including(self.container().oclAsType(EventOccurrenceSpecification).entityReference)&#xA;->collect(e | e.component)->excluding(null)->isEmpty()&#xA;or&#xA;self.container().oclAsType(EventOccurrenceSpecification).oppositeEntityReference&#xA;->including(self.container().oclAsType(EventOccurrenceSpecification).entityReference)&#xA;->collect(e | e.component)->excluding(null)&#xA;->collect(c | c.type.allGates())&#xA;->collect(g | g.type.allDataTypes())&#xA;->exists(d | self.content.resolveDataType().conformsTo(d))&#xA;)&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="content" lowerBound="1"
        eType="ecore:EClass tdl.ecore#//DataUse" containment="true"/>
@@ -132,10 +128,8 @@
      <details key="constraints" value="ContentOrValue CollectionLikeContent"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="ContentOrValue" value="self.content->isEmpty() or self.value.oclIsUndefined()"/>
      <details key="ContentOrValue$message" value="'Either nested \'Content\'s or \'Value\' may be specified within \'Content\', but not both.' + self.toString()"/>
      <details key="CollectionLikeContent" value="(not self.comment->isEmpty() and self.comment->last()._body = 'including') implies&#xA;(self.content->isEmpty() or self.content->forAll(c | c.value.oclIsUndefined()))"/>
      <details key="CollectionLikeContent$message" value="'If the \'including\' qualifier is used, directly contained \'Content\'s shall not contain a \'Value\'.' + self.toString()"/>
      <details key="ContentOrValue" value="Tuple { message : String = 'Either nested \'Content\'s or \'Value\' may be specified within \'Content\', but not both.' + self.toString(), status : Boolean = self.content->isEmpty() or self.value.oclIsUndefined()&#xA;}.status"/>
      <details key="CollectionLikeContent" value="Tuple { message : String = 'If the \'including\' qualifier is used, directly contained \'Content\'s shall not contain a \'Value\'.' + self.toString(), status : Boolean = (not self.comment->isEmpty() and self.comment->last()._body = 'including') implies&#xA;(self.content->isEmpty() or self.content->forAll(c | c.value.oclIsUndefined()))&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="value" eType="#//Value"
        containment="true"/>
@@ -148,8 +142,7 @@
      <details key="constraints" value="CollectionLikeContentLiteralValue"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="CollectionLikeContentLiteralValue" value="(not self.comment->isEmpty() and self.comment->last()._body = 'including') implies&#xA;(self.content->isEmpty() or self.content->forAll(c | c.value.oclIsUndefined()))"/>
      <details key="CollectionLikeContentLiteralValue$message" value="'If the \'including\' qualifier is used, directly contained \'Content\'s shall not contain a \'Value\'.' + self.toString()"/>
      <details key="CollectionLikeContentLiteralValue" value="Tuple { message : String = 'If the \'including\' qualifier is used, directly contained \'Content\'s shall not contain a \'Value\'.' + self.toString(), status : Boolean = (not self.comment->isEmpty() and self.comment->last()._body = 'including') implies&#xA;(self.content->isEmpty() or self.content->forAll(c | c.value.oclIsUndefined()))&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="content" ordered="false"
        upperBound="-1" eType="#//Content" containment="true"/>
@@ -160,8 +153,7 @@
      <details key="constraints" value="VisibleContent"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="VisibleContent" value="self.getTestObjective().contains(self.content)&#xA;and self.getTestObjective().indexOf(self.content) &lt; self.getTestObjective().indexOf(self)"/>
      <details key="VisibleContent$message" value="'Only \'Content\' defined within previous \'EventOccurrence\'s of the containing \'StructuredTestObjective\' may be referenced.' + self.toString()"/>
      <details key="VisibleContent" value="Tuple { message : String = 'Only \'Content\' defined within previous \'EventOccurrence\'s of the containing \'StructuredTestObjective\' may be referenced.' + self.toString(), status : Boolean = self.getTestObjective().contains(self.content)&#xA;and self.getTestObjective().indexOf(self.content) &lt; self.getTestObjective().indexOf(self)&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="content" lowerBound="1"
        eType="#//Content"/>
@@ -171,8 +163,7 @@
      <details key="constraints" value="VisibleValue"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="VisibleValue" value="self.getTestObjective().contains(self.content)&#xA;and self.getTestObjective().indexOf(self.content) &lt; self.getTestObjective().indexOf(self)"/>
      <details key="VisibleValue$message" value="'Only \'LiteralValue\'s defined within previous \'EventOccurrence\'s of the containing \'StructuredTestObjective\' may be referenced.' + self.toString()"/>
      <details key="VisibleValue" value="Tuple { message : String = 'Only \'LiteralValue\'s defined within previous \'EventOccurrence\'s of the containing \'StructuredTestObjective\' may be referenced.' + self.toString(), status : Boolean = self.getTestObjective().contains(self.content)&#xA;and self.getTestObjective().indexOf(self.content) &lt; self.getTestObjective().indexOf(self)&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="content" lowerBound="1"
        eType="#//LiteralValue"/>
@@ -182,12 +173,9 @@
      <details key="constraints" value="RepetitionOrInterval RepetitionCount RepetitionInterval"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="RepetitionOrInterval" value="self.repetitions.oclIsUndefined() or self.interval.oclIsUndefined()"/>
      <details key="RepetitionOrInterval$message" value="'At most one of the optional properties \'repetitions\' or \'interval\' shall be defined.' + self.toString()"/>
      <details key="RepetitionCount" value="true --This constraint cannot be expressed in OCL"/>
      <details key="RepetitionCount$message" value="'The expression assigned to the \'repetitions\' property shall evaluate to a positive and countable \'Value\'.' + self.toString()"/>
      <details key="RepetitionInterval" value="true --This constraint cannot be expressed in OCL"/>
      <details key="RepetitionInterval$message" value="'The expression assigned to the \'repetitions\' property shall evaluate to a positive and countable \'Value\'' + self.toString()"/>
      <details key="RepetitionOrInterval" value="Tuple { message : String = 'At most one of the optional properties \'repetitions\' or \'interval\' shall be defined.' + self.toString(), status : Boolean = self.repetitions.oclIsUndefined() or self.interval.oclIsUndefined()&#xA;}.status"/>
      <details key="RepetitionCount" value="Tuple { message : String = 'The expression assigned to the \'repetitions\' property shall evaluate to a positive and countable \'Value\'.' + self.toString(), status : Boolean = true --This constraint cannot be expressed in OCL&#xA;}.status"/>
      <details key="RepetitionInterval" value="Tuple { message : String = 'The expression assigned to the \'repetitions\' property shall evaluate to a positive and countable \'Value\'' + self.toString(), status : Boolean = true --This constraint cannot be expressed in OCL&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="repetitions" eType="#//Value"
        containment="true"/>
@@ -199,8 +187,7 @@
      <details key="constraints" value="EntityTemplateOccurrenceConsistency"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="EntityTemplateOccurrenceConsistency" value="self.entityBinding->forAll(b |&#xA;(not b.templateEntity.entity.oclIsUndefined()&#xA;and (b.templateEntity.entity =&#xA;self.eventTemplate.eventSpecification.entityReference.entity))&#xA;or (not b.templateEntity.component.oclIsUndefined()&#xA;and (b.templateEntity.component =&#xA;self.eventTemplate.eventSpecification.entityReference.component)&#xA;or self.eventTemplate.eventSpecification.oppositeEntityReference->exists(e |&#xA;(not b.templateEntity.entity.oclIsUndefined()&#xA;and (e.entity = b.templateEntity.entity))&#xA;or (not b.templateEntity.component.oclIsUndefined()&#xA;and (e.component = b.templateEntity.component)))))"/>
      <details key="EntityTemplateOccurrenceConsistency$message" value="'If \'EntityBinding\'s are provided, the \'Entity\'s or \'ComponentInstance\'s referenced in the \'templateEntity\' properties shall also be referenced by one of the \'EntityReferences\' in the \'EventOccurrenceSpecification\' of the \'EventSpecificationTemplate\' referenced in the \'EventTemplateOccurrence\'.' + self.toString()"/>
      <details key="EntityTemplateOccurrenceConsistency" value="Tuple { message : String = 'If \'EntityBinding\'s are provided, the \'Entity\'s or \'ComponentInstance\'s referenced in the \'templateEntity\' properties shall also be referenced by one of the \'EntityReferences\' in the \'EventOccurrenceSpecification\' of the \'EventSpecificationTemplate\' referenced in the \'EventTemplateOccurrence\'.' + self.toString(), status : Boolean = self.entityBinding->forAll(b |&#xA;(not b.templateEntity.entity.oclIsUndefined()&#xA;and (b.templateEntity.entity =&#xA;self.eventTemplate.eventSpecification.entityReference.entity))&#xA;or (not b.templateEntity.component.oclIsUndefined()&#xA;and (b.templateEntity.component =&#xA;self.eventTemplate.eventSpecification.entityReference.component)&#xA;or self.eventTemplate.eventSpecification.oppositeEntityReference->exists(e |&#xA;(not b.templateEntity.entity.oclIsUndefined()&#xA;and (e.entity = b.templateEntity.entity))&#xA;or (not b.templateEntity.component.oclIsUndefined()&#xA;and (e.component = b.templateEntity.component)))))&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="eventTemplate" lowerBound="1"
        eType="#//EventSpecificationTemplate"/>
@@ -238,8 +225,7 @@
      <details key="constraints" value="VariantBindingValues"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="VariantBindingValues" value="(self.value.oclIsTypeOf(LiteralValueReference) implies&#xA;self.value.oclAsType(LiteralValueReference).content.getTestObjective() = self.getTestObjective())&#xA;and&#xA;(self.value.oclIsTypeOf(ContentReference) implies&#xA;self.value.oclAsType(ContentReference).content.getTestObjective() = self.getTestObjective())"/>
      <details key="VariantBindingValues$message" value="'If the \'value\' property references a \'LiteralValue\' or \'Content\' element, the referenced element shall be contained in the \'StructuredTestObjective\' containing the \'VariantBinding\'.' + self.toString()"/>
      <details key="VariantBindingValues" value="Tuple { message : String = 'If the \'value\' property references a \'LiteralValue\' or \'Content\' element, the referenced element shall be contained in the \'StructuredTestObjective\' containing the \'VariantBinding\'.' + self.toString(), status : Boolean = (self.value.oclIsTypeOf(LiteralValueReference) implies&#xA;self.value.oclAsType(LiteralValueReference).content.getTestObjective() = self.getTestObjective())&#xA;and&#xA;(self.value.oclIsTypeOf(ContentReference) implies&#xA;self.value.oclAsType(ContentReference).content.getTestObjective() = self.getTestObjective())&#xA;}.status"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="value" lowerBound="1" eType="#//Value"
        containment="true"/>