PetriNets
PetriNet
places
trans
Place
net
itokens
tokens
Token
place
Transition
net
input
output
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="PetriNets" nsURI="http://www.petrinets.org/" nsPrefix="ex">
  <eAnnotations source="features">
    <details key="file" value="model.xml"/>
  </eAnnotations>
  <eAnnotations source="http://www.eclipse.org/OCL/Import">
    <details key="ecore" value="http://www.eclipse.org/emf/2002/Ecore"/>
  </eAnnotations>
  <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore">
    <details key="invocationDelegates" value="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot"/>
    <details key="settingDelegates" value="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot"/>
    <details key="validationDelegates" value="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot"/>
  </eAnnotations>
  <eClassifiers xsi:type="ecore:EClass" name="PetriNet">
    <eStructuralFeatures xsi:type="ecore:EReference" name="places" ordered="false"
        upperBound="-1" eType="#//Place" containment="true" eOpposite="#//Place/net">
      <eAnnotations source="http://www.eclipse.org/OCL/Collection">
        <details key="nullFree" value="false"/>
      </eAnnotations>
    </eStructuralFeatures>
    <eStructuralFeatures xsi:type="ecore:EReference" name="trans" ordered="false"
        upperBound="-1" eType="#//Transition" containment="true" eOpposite="#//Transition/net">
      <eAnnotations source="http://www.eclipse.org/OCL/Collection">
        <details key="nullFree" value="false"/>
      </eAnnotations>
    </eStructuralFeatures>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Place">
    <eAnnotations source="presence">
      <details key="constraint" value="posTokens"/>
      <details key="condition" value="Simple"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore">
      <details key="constraints" value="posTokens"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="posTokens" value="self.itokens >= 0"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="net" lowerBound="1" eType="#//PetriNet"
        eOpposite="#//PetriNet/places"/>
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="itokens" lowerBound="1"
        eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt">
      <eAnnotations source="presence">
        <details key="condition" value="Simple"/>
      </eAnnotations>
    </eStructuralFeatures>
    <eStructuralFeatures xsi:type="ecore:EReference" name="tokens" ordered="false"
        upperBound="-1" eType="#//Token" containment="true" eOpposite="#//Token/place">
      <eAnnotations source="presence">
        <details key="condition" value="Object"/>
      </eAnnotations>
      <eAnnotations source="http://www.eclipse.org/OCL/Collection">
        <details key="nullFree" value="false"/>
      </eAnnotations>
    </eStructuralFeatures>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Token">
    <eAnnotations source="presence">
      <details key="condition" value="Object"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="place" lowerBound="1" eType="#//Place"
        eOpposite="#//Place/tokens"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Transition" eSuperTypes="#//PetriNet">
    <eAnnotations source="presence">
      <details key="condition" value="Hierarchical"/>
      <details key="constraint" value="isHierarchical"/>
    </eAnnotations>
    <eAnnotations source="modifier">
      <details key="reduce" value="PetriNet"/>
      <details key="condition" value="not Hierarchical"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore">
      <details key="constraints" value="isHierarchical"/>
    </eAnnotations>
    <eAnnotations source="http://www.eclipse.org/emf/2002/Ecore/OCL/Pivot">
      <details key="isHierarchical" value="&#xA;   (places->size()>0 or trans->size()>0) &#xA;   implies &#xA;   (input->size()=0 and output->size()=0)"/>
    </eAnnotations>
    <eStructuralFeatures xsi:type="ecore:EReference" name="net" lowerBound="1" eType="#//PetriNet"
        eOpposite="#//PetriNet/trans"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="input" ordered="false"
        upperBound="-1" eType="#//Place">
      <eAnnotations source="modifier">
        <details key="condition" value="StateMachine"/>
        <details key="min" value="1"/>
        <details key="max" value="1"/>
      </eAnnotations>
      <eAnnotations source="http://www.eclipse.org/OCL/Collection">
        <details key="nullFree" value="false"/>
      </eAnnotations>
    </eStructuralFeatures>
    <eStructuralFeatures xsi:type="ecore:EReference" name="output" ordered="false"
        upperBound="-1" eType="#//Place">
      <eAnnotations source="modifier">
        <details key="condition" value="StateMachine"/>
        <details key="min" value="1"/>
        <details key="max" value="1"/>
      </eAnnotations>
      <eAnnotations source="http://www.eclipse.org/OCL/Collection">
        <details key="nullFree" value="false"/>
      </eAnnotations>
    </eStructuralFeatures>
  </eClassifiers>
</ecore:EPackage>

{"directed":true,"nodes":[{"nsPrefix":"ex","nsURI":"http://www.petrinets.org/","name":"PetriNets","id":0,"eClass":"EPackage"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"PetriNet","instanceClass":null,"abstract":false,"id":1,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Place","instanceClass":null,"abstract":false,"id":2,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Token","instanceClass":null,"abstract":false,"id":3,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Transition","instanceClass":null,"abstract":false,"id":4,"interface":false,"eClass":"EClass"},{"container":false,"ordered":false,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"places","changeable":true,"resolveProxies":true,"lowerBound":0,"id":5,"derived":false},{"container":false,"ordered":false,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"trans","changeable":true,"resolveProxies":true,"lowerBound":0,"id":6,"derived":false},{"id":7,"eClass":"EGenericType"},{"container":true,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"net","changeable":true,"resolveProxies":true,"lowerBound":1,"id":8,"derived":false},{"id":9,"eClass":"EGenericType"},{"container":true,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"net","changeable":true,"resolveProxies":true,"lowerBound":1,"id":10,"derived":false},{"ordered":true,"upperBound":1,"defaultValue":0,"volatile":false,"many":false,"required":true,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"itokens","changeable":true,"lowerBound":1,"iD":false,"id":11,"derived":false},{"container":false,"ordered":false,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"tokens","changeable":true,"resolveProxies":true,"lowerBound":0,"id":12,"derived":false},{"id":13,"eClass":"EGenericType"},{"id":14,"eClass":"EGenericType"},{"id":15,"eClass":"EGenericType"},{"container":true,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"place","changeable":true,"resolveProxies":true,"lowerBound":1,"id":16,"derived":false},{"id":17,"eClass":"EGenericType"},{"container":false,"ordered":false,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"input","changeable":true,"resolveProxies":true,"lowerBound":0,"id":18,"derived":false},{"container":false,"ordered":false,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"output","changeable":true,"resolveProxies":true,"lowerBound":0,"id":19,"derived":false},{"id":20,"eClass":"EGenericType"},{"id":21,"eClass":"EGenericType"},{"id":22,"eClass":"EGenericType"},{"id":23,"eClass":"EGenericType"}],"links":[{"source":0,"target":1},{"source":0,"target":2},{"source":0,"target":3},{"source":0,"target":4},{"source":1,"target":0},{"source":1,"target":5},{"source":1,"target":6},{"source":5,"target":2},{"source":5,"target":7},{"source":5,"target":1},{"source":5,"target":8},{"source":7,"target":2},{"source":6,"target":4},{"source":6,"target":9},{"source":6,"target":1},{"source":6,"target":10},{"source":9,"target":4},{"source":2,"target":0},{"source":2,"target":8},{"source":2,"target":11},{"source":2,"target":12},{"source":8,"target":1},{"source":8,"target":13},{"source":8,"target":2},{"source":8,"target":5},{"source":13,"target":1},{"source":11,"target":14},{"source":11,"target":2},{"source":12,"target":3},{"source":12,"target":15},{"source":12,"target":2},{"source":12,"target":16},{"source":15,"target":3},{"source":3,"target":0},{"source":3,"target":16},{"source":16,"target":2},{"source":16,"target":17},{"source":16,"target":3},{"source":16,"target":12},{"source":17,"target":2},{"source":4,"target":0},{"source":4,"target":1},{"source":4,"target":10},{"source":4,"target":18},{"source":4,"target":19},{"source":4,"target":20},{"source":10,"target":1},{"source":10,"target":21},{"source":10,"target":4},{"source":10,"target":6},{"source":21,"target":1},{"source":18,"target":2},{"source":18,"target":22},{"source":18,"target":4},{"source":22,"target":2},{"source":19,"target":2},{"source":19,"target":23},{"source":19,"target":4},{"source":23,"target":2},{"source":20,"target":1}],"multigraph":true}