diff options
author | 2019-03-20 20:39:28 -0400 | |
---|---|---|
committer | 2020-06-07 19:33:22 -0400 | |
commit | 513a5afe3a8663ad30112f7e3c0e66137938e635 (patch) | |
tree | e9ae81f529712a372bd203cb0ef2a19b9b224c95 /Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl | |
parent | Implement Containment mapping (partially) and revisit enum mapping (diff) | |
download | VIATRA-Generator-513a5afe3a8663ad30112f7e3c0e66137938e635.tar.gz VIATRA-Generator-513a5afe3a8663ad30112f7e3c0e66137938e635.tar.zst VIATRA-Generator-513a5afe3a8663ad30112f7e3c0e66137938e635.zip |
Add gitignore, commit everything
Diffstat (limited to 'Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl')
14 files changed, 2096 insertions, 0 deletions
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ChoiceImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ChoiceImpl.java new file mode 100644 index 00000000..379d4a29 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ChoiceImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Choice; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Choice</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class ChoiceImpl extends PseudostateImpl implements Choice { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected ChoiceImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.CHOICE; | ||
35 | } | ||
36 | |||
37 | } //ChoiceImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/CompositeElementImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/CompositeElementImpl.java new file mode 100644 index 00000000..067a5ee3 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/CompositeElementImpl.java | |||
@@ -0,0 +1,152 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.CompositeElement; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Region; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
8 | |||
9 | import java.util.Collection; | ||
10 | |||
11 | import org.eclipse.emf.common.notify.NotificationChain; | ||
12 | |||
13 | import org.eclipse.emf.common.util.EList; | ||
14 | |||
15 | import org.eclipse.emf.ecore.EClass; | ||
16 | import org.eclipse.emf.ecore.InternalEObject; | ||
17 | |||
18 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
19 | |||
20 | import org.eclipse.emf.ecore.util.EObjectContainmentEList; | ||
21 | import org.eclipse.emf.ecore.util.InternalEList; | ||
22 | |||
23 | /** | ||
24 | * <!-- begin-user-doc --> | ||
25 | * An implementation of the model object '<em><b>Composite Element</b></em>'. | ||
26 | * <!-- end-user-doc --> | ||
27 | * <p> | ||
28 | * The following features are implemented: | ||
29 | * </p> | ||
30 | * <ul> | ||
31 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.CompositeElementImpl#getRegions <em>Regions</em>}</li> | ||
32 | * </ul> | ||
33 | * | ||
34 | * @generated | ||
35 | */ | ||
36 | public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container implements CompositeElement { | ||
37 | /** | ||
38 | * The cached value of the '{@link #getRegions() <em>Regions</em>}' containment reference list. | ||
39 | * <!-- begin-user-doc --> | ||
40 | * <!-- end-user-doc --> | ||
41 | * @see #getRegions() | ||
42 | * @generated | ||
43 | * @ordered | ||
44 | */ | ||
45 | protected EList<Region> regions; | ||
46 | |||
47 | /** | ||
48 | * <!-- begin-user-doc --> | ||
49 | * <!-- end-user-doc --> | ||
50 | * @generated | ||
51 | */ | ||
52 | protected CompositeElementImpl() { | ||
53 | super(); | ||
54 | } | ||
55 | |||
56 | /** | ||
57 | * <!-- begin-user-doc --> | ||
58 | * <!-- end-user-doc --> | ||
59 | * @generated | ||
60 | */ | ||
61 | @Override | ||
62 | protected EClass eStaticClass() { | ||
63 | return YakindummPackage.Literals.COMPOSITE_ELEMENT; | ||
64 | } | ||
65 | |||
66 | /** | ||
67 | * <!-- begin-user-doc --> | ||
68 | * <!-- end-user-doc --> | ||
69 | * @generated | ||
70 | */ | ||
71 | public EList<Region> getRegions() { | ||
72 | if (regions == null) { | ||
73 | regions = new EObjectContainmentEList<Region>(Region.class, this, YakindummPackage.COMPOSITE_ELEMENT__REGIONS); | ||
74 | } | ||
75 | return regions; | ||
76 | } | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | @Override | ||
84 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
85 | switch (featureID) { | ||
86 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: | ||
87 | return ((InternalEList<?>)getRegions()).basicRemove(otherEnd, msgs); | ||
88 | } | ||
89 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
90 | } | ||
91 | |||
92 | /** | ||
93 | * <!-- begin-user-doc --> | ||
94 | * <!-- end-user-doc --> | ||
95 | * @generated | ||
96 | */ | ||
97 | @Override | ||
98 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
99 | switch (featureID) { | ||
100 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: | ||
101 | return getRegions(); | ||
102 | } | ||
103 | return super.eGet(featureID, resolve, coreType); | ||
104 | } | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | @SuppressWarnings("unchecked") | ||
112 | @Override | ||
113 | public void eSet(int featureID, Object newValue) { | ||
114 | switch (featureID) { | ||
115 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: | ||
116 | getRegions().clear(); | ||
117 | getRegions().addAll((Collection<? extends Region>)newValue); | ||
118 | return; | ||
119 | } | ||
120 | super.eSet(featureID, newValue); | ||
121 | } | ||
122 | |||
123 | /** | ||
124 | * <!-- begin-user-doc --> | ||
125 | * <!-- end-user-doc --> | ||
126 | * @generated | ||
127 | */ | ||
128 | @Override | ||
129 | public void eUnset(int featureID) { | ||
130 | switch (featureID) { | ||
131 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: | ||
132 | getRegions().clear(); | ||
133 | return; | ||
134 | } | ||
135 | super.eUnset(featureID); | ||
136 | } | ||
137 | |||
138 | /** | ||
139 | * <!-- begin-user-doc --> | ||
140 | * <!-- end-user-doc --> | ||
141 | * @generated | ||
142 | */ | ||
143 | @Override | ||
144 | public boolean eIsSet(int featureID) { | ||
145 | switch (featureID) { | ||
146 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: | ||
147 | return regions != null && !regions.isEmpty(); | ||
148 | } | ||
149 | return super.eIsSet(featureID); | ||
150 | } | ||
151 | |||
152 | } //CompositeElementImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/EntryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/EntryImpl.java new file mode 100644 index 00000000..0ad87100 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/EntryImpl.java | |||
@@ -0,0 +1,163 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Entry; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.EntryType; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
8 | |||
9 | import org.eclipse.emf.common.notify.Notification; | ||
10 | |||
11 | import org.eclipse.emf.ecore.EClass; | ||
12 | |||
13 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
14 | |||
15 | /** | ||
16 | * <!-- begin-user-doc --> | ||
17 | * An implementation of the model object '<em><b>Entry</b></em>'. | ||
18 | * <!-- end-user-doc --> | ||
19 | * <p> | ||
20 | * The following features are implemented: | ||
21 | * </p> | ||
22 | * <ul> | ||
23 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.EntryImpl#getType <em>Type</em>}</li> | ||
24 | * </ul> | ||
25 | * | ||
26 | * @generated | ||
27 | */ | ||
28 | public class EntryImpl extends PseudostateImpl implements Entry { | ||
29 | /** | ||
30 | * The default value of the '{@link #getType() <em>Type</em>}' attribute. | ||
31 | * <!-- begin-user-doc --> | ||
32 | * <!-- end-user-doc --> | ||
33 | * @see #getType() | ||
34 | * @generated | ||
35 | * @ordered | ||
36 | */ | ||
37 | protected static final EntryType TYPE_EDEFAULT = EntryType.NORMAL; | ||
38 | |||
39 | /** | ||
40 | * The cached value of the '{@link #getType() <em>Type</em>}' attribute. | ||
41 | * <!-- begin-user-doc --> | ||
42 | * <!-- end-user-doc --> | ||
43 | * @see #getType() | ||
44 | * @generated | ||
45 | * @ordered | ||
46 | */ | ||
47 | protected EntryType type = TYPE_EDEFAULT; | ||
48 | |||
49 | /** | ||
50 | * <!-- begin-user-doc --> | ||
51 | * <!-- end-user-doc --> | ||
52 | * @generated | ||
53 | */ | ||
54 | protected EntryImpl() { | ||
55 | super(); | ||
56 | } | ||
57 | |||
58 | /** | ||
59 | * <!-- begin-user-doc --> | ||
60 | * <!-- end-user-doc --> | ||
61 | * @generated | ||
62 | */ | ||
63 | @Override | ||
64 | protected EClass eStaticClass() { | ||
65 | return YakindummPackage.Literals.ENTRY; | ||
66 | } | ||
67 | |||
68 | /** | ||
69 | * <!-- begin-user-doc --> | ||
70 | * <!-- end-user-doc --> | ||
71 | * @generated | ||
72 | */ | ||
73 | public EntryType getType() { | ||
74 | return type; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | public void setType(EntryType newType) { | ||
83 | EntryType oldType = type; | ||
84 | type = newType == null ? TYPE_EDEFAULT : newType; | ||
85 | if (eNotificationRequired()) | ||
86 | eNotify(new ENotificationImpl(this, Notification.SET, YakindummPackage.ENTRY__TYPE, oldType, type)); | ||
87 | } | ||
88 | |||
89 | /** | ||
90 | * <!-- begin-user-doc --> | ||
91 | * <!-- end-user-doc --> | ||
92 | * @generated | ||
93 | */ | ||
94 | @Override | ||
95 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
96 | switch (featureID) { | ||
97 | case YakindummPackage.ENTRY__TYPE: | ||
98 | return getType(); | ||
99 | } | ||
100 | return super.eGet(featureID, resolve, coreType); | ||
101 | } | ||
102 | |||
103 | /** | ||
104 | * <!-- begin-user-doc --> | ||
105 | * <!-- end-user-doc --> | ||
106 | * @generated | ||
107 | */ | ||
108 | @Override | ||
109 | public void eSet(int featureID, Object newValue) { | ||
110 | switch (featureID) { | ||
111 | case YakindummPackage.ENTRY__TYPE: | ||
112 | setType((EntryType)newValue); | ||
113 | return; | ||
114 | } | ||
115 | super.eSet(featureID, newValue); | ||
116 | } | ||
117 | |||
118 | /** | ||
119 | * <!-- begin-user-doc --> | ||
120 | * <!-- end-user-doc --> | ||
121 | * @generated | ||
122 | */ | ||
123 | @Override | ||
124 | public void eUnset(int featureID) { | ||
125 | switch (featureID) { | ||
126 | case YakindummPackage.ENTRY__TYPE: | ||
127 | setType(TYPE_EDEFAULT); | ||
128 | return; | ||
129 | } | ||
130 | super.eUnset(featureID); | ||
131 | } | ||
132 | |||
133 | /** | ||
134 | * <!-- begin-user-doc --> | ||
135 | * <!-- end-user-doc --> | ||
136 | * @generated | ||
137 | */ | ||
138 | @Override | ||
139 | public boolean eIsSet(int featureID) { | ||
140 | switch (featureID) { | ||
141 | case YakindummPackage.ENTRY__TYPE: | ||
142 | return type != TYPE_EDEFAULT; | ||
143 | } | ||
144 | return super.eIsSet(featureID); | ||
145 | } | ||
146 | |||
147 | /** | ||
148 | * <!-- begin-user-doc --> | ||
149 | * <!-- end-user-doc --> | ||
150 | * @generated | ||
151 | */ | ||
152 | @Override | ||
153 | public String toString() { | ||
154 | if (eIsProxy()) return super.toString(); | ||
155 | |||
156 | StringBuilder result = new StringBuilder(super.toString()); | ||
157 | result.append(" (Type: "); | ||
158 | result.append(type); | ||
159 | result.append(')'); | ||
160 | return result.toString(); | ||
161 | } | ||
162 | |||
163 | } //EntryImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ExitImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ExitImpl.java new file mode 100644 index 00000000..ae360e68 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/ExitImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Exit; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Exit</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class ExitImpl extends PseudostateImpl implements Exit { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected ExitImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.EXIT; | ||
35 | } | ||
36 | |||
37 | } //ExitImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/FinalStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/FinalStateImpl.java new file mode 100644 index 00000000..ccb19763 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/FinalStateImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.FinalState; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Final State</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class FinalStateImpl extends RegularStateImpl implements FinalState { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected FinalStateImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.FINAL_STATE; | ||
35 | } | ||
36 | |||
37 | } //FinalStateImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/PseudostateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/PseudostateImpl.java new file mode 100644 index 00000000..b8c76c27 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/PseudostateImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Pseudostate; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Pseudostate</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public abstract class PseudostateImpl extends VertexImpl implements Pseudostate { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected PseudostateImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.PSEUDOSTATE; | ||
35 | } | ||
36 | |||
37 | } //PseudostateImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegionImpl.java new file mode 100644 index 00000000..440c389c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegionImpl.java | |||
@@ -0,0 +1,152 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Region; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Vertex; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
8 | |||
9 | import java.util.Collection; | ||
10 | |||
11 | import org.eclipse.emf.common.notify.NotificationChain; | ||
12 | |||
13 | import org.eclipse.emf.common.util.EList; | ||
14 | |||
15 | import org.eclipse.emf.ecore.EClass; | ||
16 | import org.eclipse.emf.ecore.InternalEObject; | ||
17 | |||
18 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
19 | |||
20 | import org.eclipse.emf.ecore.util.EObjectContainmentEList; | ||
21 | import org.eclipse.emf.ecore.util.InternalEList; | ||
22 | |||
23 | /** | ||
24 | * <!-- begin-user-doc --> | ||
25 | * An implementation of the model object '<em><b>Region</b></em>'. | ||
26 | * <!-- end-user-doc --> | ||
27 | * <p> | ||
28 | * The following features are implemented: | ||
29 | * </p> | ||
30 | * <ul> | ||
31 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.RegionImpl#getVertices <em>Vertices</em>}</li> | ||
32 | * </ul> | ||
33 | * | ||
34 | * @generated | ||
35 | */ | ||
36 | public class RegionImpl extends MinimalEObjectImpl.Container implements Region { | ||
37 | /** | ||
38 | * The cached value of the '{@link #getVertices() <em>Vertices</em>}' containment reference list. | ||
39 | * <!-- begin-user-doc --> | ||
40 | * <!-- end-user-doc --> | ||
41 | * @see #getVertices() | ||
42 | * @generated | ||
43 | * @ordered | ||
44 | */ | ||
45 | protected EList<Vertex> vertices; | ||
46 | |||
47 | /** | ||
48 | * <!-- begin-user-doc --> | ||
49 | * <!-- end-user-doc --> | ||
50 | * @generated | ||
51 | */ | ||
52 | protected RegionImpl() { | ||
53 | super(); | ||
54 | } | ||
55 | |||
56 | /** | ||
57 | * <!-- begin-user-doc --> | ||
58 | * <!-- end-user-doc --> | ||
59 | * @generated | ||
60 | */ | ||
61 | @Override | ||
62 | protected EClass eStaticClass() { | ||
63 | return YakindummPackage.Literals.REGION; | ||
64 | } | ||
65 | |||
66 | /** | ||
67 | * <!-- begin-user-doc --> | ||
68 | * <!-- end-user-doc --> | ||
69 | * @generated | ||
70 | */ | ||
71 | public EList<Vertex> getVertices() { | ||
72 | if (vertices == null) { | ||
73 | vertices = new EObjectContainmentEList<Vertex>(Vertex.class, this, YakindummPackage.REGION__VERTICES); | ||
74 | } | ||
75 | return vertices; | ||
76 | } | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | @Override | ||
84 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
85 | switch (featureID) { | ||
86 | case YakindummPackage.REGION__VERTICES: | ||
87 | return ((InternalEList<?>)getVertices()).basicRemove(otherEnd, msgs); | ||
88 | } | ||
89 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
90 | } | ||
91 | |||
92 | /** | ||
93 | * <!-- begin-user-doc --> | ||
94 | * <!-- end-user-doc --> | ||
95 | * @generated | ||
96 | */ | ||
97 | @Override | ||
98 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
99 | switch (featureID) { | ||
100 | case YakindummPackage.REGION__VERTICES: | ||
101 | return getVertices(); | ||
102 | } | ||
103 | return super.eGet(featureID, resolve, coreType); | ||
104 | } | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | @SuppressWarnings("unchecked") | ||
112 | @Override | ||
113 | public void eSet(int featureID, Object newValue) { | ||
114 | switch (featureID) { | ||
115 | case YakindummPackage.REGION__VERTICES: | ||
116 | getVertices().clear(); | ||
117 | getVertices().addAll((Collection<? extends Vertex>)newValue); | ||
118 | return; | ||
119 | } | ||
120 | super.eSet(featureID, newValue); | ||
121 | } | ||
122 | |||
123 | /** | ||
124 | * <!-- begin-user-doc --> | ||
125 | * <!-- end-user-doc --> | ||
126 | * @generated | ||
127 | */ | ||
128 | @Override | ||
129 | public void eUnset(int featureID) { | ||
130 | switch (featureID) { | ||
131 | case YakindummPackage.REGION__VERTICES: | ||
132 | getVertices().clear(); | ||
133 | return; | ||
134 | } | ||
135 | super.eUnset(featureID); | ||
136 | } | ||
137 | |||
138 | /** | ||
139 | * <!-- begin-user-doc --> | ||
140 | * <!-- end-user-doc --> | ||
141 | * @generated | ||
142 | */ | ||
143 | @Override | ||
144 | public boolean eIsSet(int featureID) { | ||
145 | switch (featureID) { | ||
146 | case YakindummPackage.REGION__VERTICES: | ||
147 | return vertices != null && !vertices.isEmpty(); | ||
148 | } | ||
149 | return super.eIsSet(featureID); | ||
150 | } | ||
151 | |||
152 | } //RegionImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegularStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegularStateImpl.java new file mode 100644 index 00000000..2ada6da9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/RegularStateImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.RegularState; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Regular State</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public abstract class RegularStateImpl extends VertexImpl implements RegularState { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected RegularStateImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.REGULAR_STATE; | ||
35 | } | ||
36 | |||
37 | } //RegularStateImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StateImpl.java new file mode 100644 index 00000000..080bed16 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StateImpl.java | |||
@@ -0,0 +1,183 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.CompositeElement; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Region; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.State; | ||
8 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
9 | |||
10 | import java.util.Collection; | ||
11 | |||
12 | import org.eclipse.emf.common.notify.NotificationChain; | ||
13 | |||
14 | import org.eclipse.emf.common.util.EList; | ||
15 | |||
16 | import org.eclipse.emf.ecore.EClass; | ||
17 | import org.eclipse.emf.ecore.InternalEObject; | ||
18 | |||
19 | import org.eclipse.emf.ecore.util.EObjectContainmentEList; | ||
20 | import org.eclipse.emf.ecore.util.InternalEList; | ||
21 | |||
22 | /** | ||
23 | * <!-- begin-user-doc --> | ||
24 | * An implementation of the model object '<em><b>State</b></em>'. | ||
25 | * <!-- end-user-doc --> | ||
26 | * <p> | ||
27 | * The following features are implemented: | ||
28 | * </p> | ||
29 | * <ul> | ||
30 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.StateImpl#getRegions <em>Regions</em>}</li> | ||
31 | * </ul> | ||
32 | * | ||
33 | * @generated | ||
34 | */ | ||
35 | public class StateImpl extends RegularStateImpl implements State { | ||
36 | /** | ||
37 | * The cached value of the '{@link #getRegions() <em>Regions</em>}' containment reference list. | ||
38 | * <!-- begin-user-doc --> | ||
39 | * <!-- end-user-doc --> | ||
40 | * @see #getRegions() | ||
41 | * @generated | ||
42 | * @ordered | ||
43 | */ | ||
44 | protected EList<Region> regions; | ||
45 | |||
46 | /** | ||
47 | * <!-- begin-user-doc --> | ||
48 | * <!-- end-user-doc --> | ||
49 | * @generated | ||
50 | */ | ||
51 | protected StateImpl() { | ||
52 | super(); | ||
53 | } | ||
54 | |||
55 | /** | ||
56 | * <!-- begin-user-doc --> | ||
57 | * <!-- end-user-doc --> | ||
58 | * @generated | ||
59 | */ | ||
60 | @Override | ||
61 | protected EClass eStaticClass() { | ||
62 | return YakindummPackage.Literals.STATE; | ||
63 | } | ||
64 | |||
65 | /** | ||
66 | * <!-- begin-user-doc --> | ||
67 | * <!-- end-user-doc --> | ||
68 | * @generated | ||
69 | */ | ||
70 | public EList<Region> getRegions() { | ||
71 | if (regions == null) { | ||
72 | regions = new EObjectContainmentEList<Region>(Region.class, this, YakindummPackage.STATE__REGIONS); | ||
73 | } | ||
74 | return regions; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
84 | switch (featureID) { | ||
85 | case YakindummPackage.STATE__REGIONS: | ||
86 | return ((InternalEList<?>)getRegions()).basicRemove(otherEnd, msgs); | ||
87 | } | ||
88 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
89 | } | ||
90 | |||
91 | /** | ||
92 | * <!-- begin-user-doc --> | ||
93 | * <!-- end-user-doc --> | ||
94 | * @generated | ||
95 | */ | ||
96 | @Override | ||
97 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
98 | switch (featureID) { | ||
99 | case YakindummPackage.STATE__REGIONS: | ||
100 | return getRegions(); | ||
101 | } | ||
102 | return super.eGet(featureID, resolve, coreType); | ||
103 | } | ||
104 | |||
105 | /** | ||
106 | * <!-- begin-user-doc --> | ||
107 | * <!-- end-user-doc --> | ||
108 | * @generated | ||
109 | */ | ||
110 | @SuppressWarnings("unchecked") | ||
111 | @Override | ||
112 | public void eSet(int featureID, Object newValue) { | ||
113 | switch (featureID) { | ||
114 | case YakindummPackage.STATE__REGIONS: | ||
115 | getRegions().clear(); | ||
116 | getRegions().addAll((Collection<? extends Region>)newValue); | ||
117 | return; | ||
118 | } | ||
119 | super.eSet(featureID, newValue); | ||
120 | } | ||
121 | |||
122 | /** | ||
123 | * <!-- begin-user-doc --> | ||
124 | * <!-- end-user-doc --> | ||
125 | * @generated | ||
126 | */ | ||
127 | @Override | ||
128 | public void eUnset(int featureID) { | ||
129 | switch (featureID) { | ||
130 | case YakindummPackage.STATE__REGIONS: | ||
131 | getRegions().clear(); | ||
132 | return; | ||
133 | } | ||
134 | super.eUnset(featureID); | ||
135 | } | ||
136 | |||
137 | /** | ||
138 | * <!-- begin-user-doc --> | ||
139 | * <!-- end-user-doc --> | ||
140 | * @generated | ||
141 | */ | ||
142 | @Override | ||
143 | public boolean eIsSet(int featureID) { | ||
144 | switch (featureID) { | ||
145 | case YakindummPackage.STATE__REGIONS: | ||
146 | return regions != null && !regions.isEmpty(); | ||
147 | } | ||
148 | return super.eIsSet(featureID); | ||
149 | } | ||
150 | |||
151 | /** | ||
152 | * <!-- begin-user-doc --> | ||
153 | * <!-- end-user-doc --> | ||
154 | * @generated | ||
155 | */ | ||
156 | @Override | ||
157 | public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) { | ||
158 | if (baseClass == CompositeElement.class) { | ||
159 | switch (derivedFeatureID) { | ||
160 | case YakindummPackage.STATE__REGIONS: return YakindummPackage.COMPOSITE_ELEMENT__REGIONS; | ||
161 | default: return -1; | ||
162 | } | ||
163 | } | ||
164 | return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); | ||
165 | } | ||
166 | |||
167 | /** | ||
168 | * <!-- begin-user-doc --> | ||
169 | * <!-- end-user-doc --> | ||
170 | * @generated | ||
171 | */ | ||
172 | @Override | ||
173 | public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass) { | ||
174 | if (baseClass == CompositeElement.class) { | ||
175 | switch (baseFeatureID) { | ||
176 | case YakindummPackage.COMPOSITE_ELEMENT__REGIONS: return YakindummPackage.STATE__REGIONS; | ||
177 | default: return -1; | ||
178 | } | ||
179 | } | ||
180 | return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); | ||
181 | } | ||
182 | |||
183 | } //StateImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StatechartImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StatechartImpl.java new file mode 100644 index 00000000..0b48e8d8 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/StatechartImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Statechart; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Statechart</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class StatechartImpl extends CompositeElementImpl implements Statechart { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected StatechartImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return YakindummPackage.Literals.STATECHART; | ||
35 | } | ||
36 | |||
37 | } //StatechartImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/TransitionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/TransitionImpl.java new file mode 100644 index 00000000..875964a2 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/TransitionImpl.java | |||
@@ -0,0 +1,284 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Transition; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Vertex; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
8 | |||
9 | import org.eclipse.emf.common.notify.Notification; | ||
10 | import org.eclipse.emf.common.notify.NotificationChain; | ||
11 | |||
12 | import org.eclipse.emf.ecore.EClass; | ||
13 | import org.eclipse.emf.ecore.InternalEObject; | ||
14 | |||
15 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
16 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
17 | |||
18 | import org.eclipse.emf.ecore.util.EcoreUtil; | ||
19 | |||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * An implementation of the model object '<em><b>Transition</b></em>'. | ||
23 | * <!-- end-user-doc --> | ||
24 | * <p> | ||
25 | * The following features are implemented: | ||
26 | * </p> | ||
27 | * <ul> | ||
28 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.TransitionImpl#getTarget <em>Target</em>}</li> | ||
29 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.TransitionImpl#getSource <em>Source</em>}</li> | ||
30 | * </ul> | ||
31 | * | ||
32 | * @generated | ||
33 | */ | ||
34 | public class TransitionImpl extends MinimalEObjectImpl.Container implements Transition { | ||
35 | /** | ||
36 | * The cached value of the '{@link #getTarget() <em>Target</em>}' reference. | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @see #getTarget() | ||
40 | * @generated | ||
41 | * @ordered | ||
42 | */ | ||
43 | protected Vertex target; | ||
44 | |||
45 | /** | ||
46 | * <!-- begin-user-doc --> | ||
47 | * <!-- end-user-doc --> | ||
48 | * @generated | ||
49 | */ | ||
50 | protected TransitionImpl() { | ||
51 | super(); | ||
52 | } | ||
53 | |||
54 | /** | ||
55 | * <!-- begin-user-doc --> | ||
56 | * <!-- end-user-doc --> | ||
57 | * @generated | ||
58 | */ | ||
59 | @Override | ||
60 | protected EClass eStaticClass() { | ||
61 | return YakindummPackage.Literals.TRANSITION; | ||
62 | } | ||
63 | |||
64 | /** | ||
65 | * <!-- begin-user-doc --> | ||
66 | * <!-- end-user-doc --> | ||
67 | * @generated | ||
68 | */ | ||
69 | public Vertex getTarget() { | ||
70 | if (target != null && target.eIsProxy()) { | ||
71 | InternalEObject oldTarget = (InternalEObject)target; | ||
72 | target = (Vertex)eResolveProxy(oldTarget); | ||
73 | if (target != oldTarget) { | ||
74 | if (eNotificationRequired()) | ||
75 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, YakindummPackage.TRANSITION__TARGET, oldTarget, target)); | ||
76 | } | ||
77 | } | ||
78 | return target; | ||
79 | } | ||
80 | |||
81 | /** | ||
82 | * <!-- begin-user-doc --> | ||
83 | * <!-- end-user-doc --> | ||
84 | * @generated | ||
85 | */ | ||
86 | public Vertex basicGetTarget() { | ||
87 | return target; | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | public NotificationChain basicSetTarget(Vertex newTarget, NotificationChain msgs) { | ||
96 | Vertex oldTarget = target; | ||
97 | target = newTarget; | ||
98 | if (eNotificationRequired()) { | ||
99 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, YakindummPackage.TRANSITION__TARGET, oldTarget, newTarget); | ||
100 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
101 | } | ||
102 | return msgs; | ||
103 | } | ||
104 | |||
105 | /** | ||
106 | * <!-- begin-user-doc --> | ||
107 | * <!-- end-user-doc --> | ||
108 | * @generated | ||
109 | */ | ||
110 | public void setTarget(Vertex newTarget) { | ||
111 | if (newTarget != target) { | ||
112 | NotificationChain msgs = null; | ||
113 | if (target != null) | ||
114 | msgs = ((InternalEObject)target).eInverseRemove(this, YakindummPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); | ||
115 | if (newTarget != null) | ||
116 | msgs = ((InternalEObject)newTarget).eInverseAdd(this, YakindummPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); | ||
117 | msgs = basicSetTarget(newTarget, msgs); | ||
118 | if (msgs != null) msgs.dispatch(); | ||
119 | } | ||
120 | else if (eNotificationRequired()) | ||
121 | eNotify(new ENotificationImpl(this, Notification.SET, YakindummPackage.TRANSITION__TARGET, newTarget, newTarget)); | ||
122 | } | ||
123 | |||
124 | /** | ||
125 | * <!-- begin-user-doc --> | ||
126 | * <!-- end-user-doc --> | ||
127 | * @generated | ||
128 | */ | ||
129 | public Vertex getSource() { | ||
130 | if (eContainerFeatureID() != YakindummPackage.TRANSITION__SOURCE) return null; | ||
131 | return (Vertex)eInternalContainer(); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | public NotificationChain basicSetSource(Vertex newSource, NotificationChain msgs) { | ||
140 | msgs = eBasicSetContainer((InternalEObject)newSource, YakindummPackage.TRANSITION__SOURCE, msgs); | ||
141 | return msgs; | ||
142 | } | ||
143 | |||
144 | /** | ||
145 | * <!-- begin-user-doc --> | ||
146 | * <!-- end-user-doc --> | ||
147 | * @generated | ||
148 | */ | ||
149 | public void setSource(Vertex newSource) { | ||
150 | if (newSource != eInternalContainer() || (eContainerFeatureID() != YakindummPackage.TRANSITION__SOURCE && newSource != null)) { | ||
151 | if (EcoreUtil.isAncestor(this, newSource)) | ||
152 | throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); | ||
153 | NotificationChain msgs = null; | ||
154 | if (eInternalContainer() != null) | ||
155 | msgs = eBasicRemoveFromContainer(msgs); | ||
156 | if (newSource != null) | ||
157 | msgs = ((InternalEObject)newSource).eInverseAdd(this, YakindummPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); | ||
158 | msgs = basicSetSource(newSource, msgs); | ||
159 | if (msgs != null) msgs.dispatch(); | ||
160 | } | ||
161 | else if (eNotificationRequired()) | ||
162 | eNotify(new ENotificationImpl(this, Notification.SET, YakindummPackage.TRANSITION__SOURCE, newSource, newSource)); | ||
163 | } | ||
164 | |||
165 | /** | ||
166 | * <!-- begin-user-doc --> | ||
167 | * <!-- end-user-doc --> | ||
168 | * @generated | ||
169 | */ | ||
170 | @Override | ||
171 | public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
172 | switch (featureID) { | ||
173 | case YakindummPackage.TRANSITION__TARGET: | ||
174 | if (target != null) | ||
175 | msgs = ((InternalEObject)target).eInverseRemove(this, YakindummPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); | ||
176 | return basicSetTarget((Vertex)otherEnd, msgs); | ||
177 | case YakindummPackage.TRANSITION__SOURCE: | ||
178 | if (eInternalContainer() != null) | ||
179 | msgs = eBasicRemoveFromContainer(msgs); | ||
180 | return basicSetSource((Vertex)otherEnd, msgs); | ||
181 | } | ||
182 | return super.eInverseAdd(otherEnd, featureID, msgs); | ||
183 | } | ||
184 | |||
185 | /** | ||
186 | * <!-- begin-user-doc --> | ||
187 | * <!-- end-user-doc --> | ||
188 | * @generated | ||
189 | */ | ||
190 | @Override | ||
191 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
192 | switch (featureID) { | ||
193 | case YakindummPackage.TRANSITION__TARGET: | ||
194 | return basicSetTarget(null, msgs); | ||
195 | case YakindummPackage.TRANSITION__SOURCE: | ||
196 | return basicSetSource(null, msgs); | ||
197 | } | ||
198 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
199 | } | ||
200 | |||
201 | /** | ||
202 | * <!-- begin-user-doc --> | ||
203 | * <!-- end-user-doc --> | ||
204 | * @generated | ||
205 | */ | ||
206 | @Override | ||
207 | public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { | ||
208 | switch (eContainerFeatureID()) { | ||
209 | case YakindummPackage.TRANSITION__SOURCE: | ||
210 | return eInternalContainer().eInverseRemove(this, YakindummPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); | ||
211 | } | ||
212 | return super.eBasicRemoveFromContainerFeature(msgs); | ||
213 | } | ||
214 | |||
215 | /** | ||
216 | * <!-- begin-user-doc --> | ||
217 | * <!-- end-user-doc --> | ||
218 | * @generated | ||
219 | */ | ||
220 | @Override | ||
221 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
222 | switch (featureID) { | ||
223 | case YakindummPackage.TRANSITION__TARGET: | ||
224 | if (resolve) return getTarget(); | ||
225 | return basicGetTarget(); | ||
226 | case YakindummPackage.TRANSITION__SOURCE: | ||
227 | return getSource(); | ||
228 | } | ||
229 | return super.eGet(featureID, resolve, coreType); | ||
230 | } | ||
231 | |||
232 | /** | ||
233 | * <!-- begin-user-doc --> | ||
234 | * <!-- end-user-doc --> | ||
235 | * @generated | ||
236 | */ | ||
237 | @Override | ||
238 | public void eSet(int featureID, Object newValue) { | ||
239 | switch (featureID) { | ||
240 | case YakindummPackage.TRANSITION__TARGET: | ||
241 | setTarget((Vertex)newValue); | ||
242 | return; | ||
243 | case YakindummPackage.TRANSITION__SOURCE: | ||
244 | setSource((Vertex)newValue); | ||
245 | return; | ||
246 | } | ||
247 | super.eSet(featureID, newValue); | ||
248 | } | ||
249 | |||
250 | /** | ||
251 | * <!-- begin-user-doc --> | ||
252 | * <!-- end-user-doc --> | ||
253 | * @generated | ||
254 | */ | ||
255 | @Override | ||
256 | public void eUnset(int featureID) { | ||
257 | switch (featureID) { | ||
258 | case YakindummPackage.TRANSITION__TARGET: | ||
259 | setTarget((Vertex)null); | ||
260 | return; | ||
261 | case YakindummPackage.TRANSITION__SOURCE: | ||
262 | setSource((Vertex)null); | ||
263 | return; | ||
264 | } | ||
265 | super.eUnset(featureID); | ||
266 | } | ||
267 | |||
268 | /** | ||
269 | * <!-- begin-user-doc --> | ||
270 | * <!-- end-user-doc --> | ||
271 | * @generated | ||
272 | */ | ||
273 | @Override | ||
274 | public boolean eIsSet(int featureID) { | ||
275 | switch (featureID) { | ||
276 | case YakindummPackage.TRANSITION__TARGET: | ||
277 | return target != null; | ||
278 | case YakindummPackage.TRANSITION__SOURCE: | ||
279 | return getSource() != null; | ||
280 | } | ||
281 | return super.eIsSet(featureID); | ||
282 | } | ||
283 | |||
284 | } //TransitionImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/VertexImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/VertexImpl.java new file mode 100644 index 00000000..66871f3f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/VertexImpl.java | |||
@@ -0,0 +1,206 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Transition; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Vertex; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
8 | |||
9 | import java.util.Collection; | ||
10 | |||
11 | import org.eclipse.emf.common.notify.NotificationChain; | ||
12 | |||
13 | import org.eclipse.emf.common.util.EList; | ||
14 | |||
15 | import org.eclipse.emf.ecore.EClass; | ||
16 | import org.eclipse.emf.ecore.InternalEObject; | ||
17 | |||
18 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
19 | |||
20 | import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; | ||
21 | import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; | ||
22 | import org.eclipse.emf.ecore.util.InternalEList; | ||
23 | |||
24 | /** | ||
25 | * <!-- begin-user-doc --> | ||
26 | * An implementation of the model object '<em><b>Vertex</b></em>'. | ||
27 | * <!-- end-user-doc --> | ||
28 | * <p> | ||
29 | * The following features are implemented: | ||
30 | * </p> | ||
31 | * <ul> | ||
32 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.VertexImpl#getIncomingTransitions <em>Incoming Transitions</em>}</li> | ||
33 | * <li>{@link ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl.VertexImpl#getOutgoingTransitions <em>Outgoing Transitions</em>}</li> | ||
34 | * </ul> | ||
35 | * | ||
36 | * @generated | ||
37 | */ | ||
38 | public abstract class VertexImpl extends MinimalEObjectImpl.Container implements Vertex { | ||
39 | /** | ||
40 | * The cached value of the '{@link #getIncomingTransitions() <em>Incoming Transitions</em>}' reference list. | ||
41 | * <!-- begin-user-doc --> | ||
42 | * <!-- end-user-doc --> | ||
43 | * @see #getIncomingTransitions() | ||
44 | * @generated | ||
45 | * @ordered | ||
46 | */ | ||
47 | protected EList<Transition> incomingTransitions; | ||
48 | |||
49 | /** | ||
50 | * The cached value of the '{@link #getOutgoingTransitions() <em>Outgoing Transitions</em>}' containment reference list. | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @see #getOutgoingTransitions() | ||
54 | * @generated | ||
55 | * @ordered | ||
56 | */ | ||
57 | protected EList<Transition> outgoingTransitions; | ||
58 | |||
59 | /** | ||
60 | * <!-- begin-user-doc --> | ||
61 | * <!-- end-user-doc --> | ||
62 | * @generated | ||
63 | */ | ||
64 | protected VertexImpl() { | ||
65 | super(); | ||
66 | } | ||
67 | |||
68 | /** | ||
69 | * <!-- begin-user-doc --> | ||
70 | * <!-- end-user-doc --> | ||
71 | * @generated | ||
72 | */ | ||
73 | @Override | ||
74 | protected EClass eStaticClass() { | ||
75 | return YakindummPackage.Literals.VERTEX; | ||
76 | } | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | public EList<Transition> getIncomingTransitions() { | ||
84 | if (incomingTransitions == null) { | ||
85 | incomingTransitions = new EObjectWithInverseResolvingEList<Transition>(Transition.class, this, YakindummPackage.VERTEX__INCOMING_TRANSITIONS, YakindummPackage.TRANSITION__TARGET); | ||
86 | } | ||
87 | return incomingTransitions; | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | public EList<Transition> getOutgoingTransitions() { | ||
96 | if (outgoingTransitions == null) { | ||
97 | outgoingTransitions = new EObjectContainmentWithInverseEList<Transition>(Transition.class, this, YakindummPackage.VERTEX__OUTGOING_TRANSITIONS, YakindummPackage.TRANSITION__SOURCE); | ||
98 | } | ||
99 | return outgoingTransitions; | ||
100 | } | ||
101 | |||
102 | /** | ||
103 | * <!-- begin-user-doc --> | ||
104 | * <!-- end-user-doc --> | ||
105 | * @generated | ||
106 | */ | ||
107 | @SuppressWarnings("unchecked") | ||
108 | @Override | ||
109 | public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
110 | switch (featureID) { | ||
111 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
112 | return ((InternalEList<InternalEObject>)(InternalEList<?>)getIncomingTransitions()).basicAdd(otherEnd, msgs); | ||
113 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
114 | return ((InternalEList<InternalEObject>)(InternalEList<?>)getOutgoingTransitions()).basicAdd(otherEnd, msgs); | ||
115 | } | ||
116 | return super.eInverseAdd(otherEnd, featureID, msgs); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
126 | switch (featureID) { | ||
127 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
128 | return ((InternalEList<?>)getIncomingTransitions()).basicRemove(otherEnd, msgs); | ||
129 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
130 | return ((InternalEList<?>)getOutgoingTransitions()).basicRemove(otherEnd, msgs); | ||
131 | } | ||
132 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
133 | } | ||
134 | |||
135 | /** | ||
136 | * <!-- begin-user-doc --> | ||
137 | * <!-- end-user-doc --> | ||
138 | * @generated | ||
139 | */ | ||
140 | @Override | ||
141 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
142 | switch (featureID) { | ||
143 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
144 | return getIncomingTransitions(); | ||
145 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
146 | return getOutgoingTransitions(); | ||
147 | } | ||
148 | return super.eGet(featureID, resolve, coreType); | ||
149 | } | ||
150 | |||
151 | /** | ||
152 | * <!-- begin-user-doc --> | ||
153 | * <!-- end-user-doc --> | ||
154 | * @generated | ||
155 | */ | ||
156 | @SuppressWarnings("unchecked") | ||
157 | @Override | ||
158 | public void eSet(int featureID, Object newValue) { | ||
159 | switch (featureID) { | ||
160 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
161 | getIncomingTransitions().clear(); | ||
162 | getIncomingTransitions().addAll((Collection<? extends Transition>)newValue); | ||
163 | return; | ||
164 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
165 | getOutgoingTransitions().clear(); | ||
166 | getOutgoingTransitions().addAll((Collection<? extends Transition>)newValue); | ||
167 | return; | ||
168 | } | ||
169 | super.eSet(featureID, newValue); | ||
170 | } | ||
171 | |||
172 | /** | ||
173 | * <!-- begin-user-doc --> | ||
174 | * <!-- end-user-doc --> | ||
175 | * @generated | ||
176 | */ | ||
177 | @Override | ||
178 | public void eUnset(int featureID) { | ||
179 | switch (featureID) { | ||
180 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
181 | getIncomingTransitions().clear(); | ||
182 | return; | ||
183 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
184 | getOutgoingTransitions().clear(); | ||
185 | return; | ||
186 | } | ||
187 | super.eUnset(featureID); | ||
188 | } | ||
189 | |||
190 | /** | ||
191 | * <!-- begin-user-doc --> | ||
192 | * <!-- end-user-doc --> | ||
193 | * @generated | ||
194 | */ | ||
195 | @Override | ||
196 | public boolean eIsSet(int featureID) { | ||
197 | switch (featureID) { | ||
198 | case YakindummPackage.VERTEX__INCOMING_TRANSITIONS: | ||
199 | return incomingTransitions != null && !incomingTransitions.isEmpty(); | ||
200 | case YakindummPackage.VERTEX__OUTGOING_TRANSITIONS: | ||
201 | return outgoingTransitions != null && !outgoingTransitions.isEmpty(); | ||
202 | } | ||
203 | return super.eIsSet(featureID); | ||
204 | } | ||
205 | |||
206 | } //VertexImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummFactoryImpl.java new file mode 100644 index 00000000..d4be344f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummFactoryImpl.java | |||
@@ -0,0 +1,223 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.*; | ||
6 | |||
7 | import org.eclipse.emf.ecore.EClass; | ||
8 | import org.eclipse.emf.ecore.EDataType; | ||
9 | import org.eclipse.emf.ecore.EObject; | ||
10 | import org.eclipse.emf.ecore.EPackage; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.EFactoryImpl; | ||
13 | |||
14 | import org.eclipse.emf.ecore.plugin.EcorePlugin; | ||
15 | |||
16 | /** | ||
17 | * <!-- begin-user-doc --> | ||
18 | * An implementation of the model <b>Factory</b>. | ||
19 | * <!-- end-user-doc --> | ||
20 | * @generated | ||
21 | */ | ||
22 | public class YakindummFactoryImpl extends EFactoryImpl implements YakindummFactory { | ||
23 | /** | ||
24 | * Creates the default factory implementation. | ||
25 | * <!-- begin-user-doc --> | ||
26 | * <!-- end-user-doc --> | ||
27 | * @generated | ||
28 | */ | ||
29 | public static YakindummFactory init() { | ||
30 | try { | ||
31 | YakindummFactory theYakindummFactory = (YakindummFactory)EPackage.Registry.INSTANCE.getEFactory(YakindummPackage.eNS_URI); | ||
32 | if (theYakindummFactory != null) { | ||
33 | return theYakindummFactory; | ||
34 | } | ||
35 | } | ||
36 | catch (Exception exception) { | ||
37 | EcorePlugin.INSTANCE.log(exception); | ||
38 | } | ||
39 | return new YakindummFactoryImpl(); | ||
40 | } | ||
41 | |||
42 | /** | ||
43 | * Creates an instance of the factory. | ||
44 | * <!-- begin-user-doc --> | ||
45 | * <!-- end-user-doc --> | ||
46 | * @generated | ||
47 | */ | ||
48 | public YakindummFactoryImpl() { | ||
49 | super(); | ||
50 | } | ||
51 | |||
52 | /** | ||
53 | * <!-- begin-user-doc --> | ||
54 | * <!-- end-user-doc --> | ||
55 | * @generated | ||
56 | */ | ||
57 | @Override | ||
58 | public EObject create(EClass eClass) { | ||
59 | switch (eClass.getClassifierID()) { | ||
60 | case YakindummPackage.REGION: return createRegion(); | ||
61 | case YakindummPackage.TRANSITION: return createTransition(); | ||
62 | case YakindummPackage.STATECHART: return createStatechart(); | ||
63 | case YakindummPackage.ENTRY: return createEntry(); | ||
64 | case YakindummPackage.STATE: return createState(); | ||
65 | case YakindummPackage.CHOICE: return createChoice(); | ||
66 | case YakindummPackage.EXIT: return createExit(); | ||
67 | case YakindummPackage.FINAL_STATE: return createFinalState(); | ||
68 | default: | ||
69 | throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); | ||
70 | } | ||
71 | } | ||
72 | |||
73 | /** | ||
74 | * <!-- begin-user-doc --> | ||
75 | * <!-- end-user-doc --> | ||
76 | * @generated | ||
77 | */ | ||
78 | @Override | ||
79 | public Object createFromString(EDataType eDataType, String initialValue) { | ||
80 | switch (eDataType.getClassifierID()) { | ||
81 | case YakindummPackage.ENTRY_TYPE: | ||
82 | return createEntryTypeFromString(eDataType, initialValue); | ||
83 | default: | ||
84 | throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); | ||
85 | } | ||
86 | } | ||
87 | |||
88 | /** | ||
89 | * <!-- begin-user-doc --> | ||
90 | * <!-- end-user-doc --> | ||
91 | * @generated | ||
92 | */ | ||
93 | @Override | ||
94 | public String convertToString(EDataType eDataType, Object instanceValue) { | ||
95 | switch (eDataType.getClassifierID()) { | ||
96 | case YakindummPackage.ENTRY_TYPE: | ||
97 | return convertEntryTypeToString(eDataType, instanceValue); | ||
98 | default: | ||
99 | throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); | ||
100 | } | ||
101 | } | ||
102 | |||
103 | /** | ||
104 | * <!-- begin-user-doc --> | ||
105 | * <!-- end-user-doc --> | ||
106 | * @generated | ||
107 | */ | ||
108 | public Region createRegion() { | ||
109 | RegionImpl region = new RegionImpl(); | ||
110 | return region; | ||
111 | } | ||
112 | |||
113 | /** | ||
114 | * <!-- begin-user-doc --> | ||
115 | * <!-- end-user-doc --> | ||
116 | * @generated | ||
117 | */ | ||
118 | public Transition createTransition() { | ||
119 | TransitionImpl transition = new TransitionImpl(); | ||
120 | return transition; | ||
121 | } | ||
122 | |||
123 | /** | ||
124 | * <!-- begin-user-doc --> | ||
125 | * <!-- end-user-doc --> | ||
126 | * @generated | ||
127 | */ | ||
128 | public Statechart createStatechart() { | ||
129 | StatechartImpl statechart = new StatechartImpl(); | ||
130 | return statechart; | ||
131 | } | ||
132 | |||
133 | /** | ||
134 | * <!-- begin-user-doc --> | ||
135 | * <!-- end-user-doc --> | ||
136 | * @generated | ||
137 | */ | ||
138 | public Entry createEntry() { | ||
139 | EntryImpl entry = new EntryImpl(); | ||
140 | return entry; | ||
141 | } | ||
142 | |||
143 | /** | ||
144 | * <!-- begin-user-doc --> | ||
145 | * <!-- end-user-doc --> | ||
146 | * @generated | ||
147 | */ | ||
148 | public State createState() { | ||
149 | StateImpl state = new StateImpl(); | ||
150 | return state; | ||
151 | } | ||
152 | |||
153 | /** | ||
154 | * <!-- begin-user-doc --> | ||
155 | * <!-- end-user-doc --> | ||
156 | * @generated | ||
157 | */ | ||
158 | public Choice createChoice() { | ||
159 | ChoiceImpl choice = new ChoiceImpl(); | ||
160 | return choice; | ||
161 | } | ||
162 | |||
163 | /** | ||
164 | * <!-- begin-user-doc --> | ||
165 | * <!-- end-user-doc --> | ||
166 | * @generated | ||
167 | */ | ||
168 | public Exit createExit() { | ||
169 | ExitImpl exit = new ExitImpl(); | ||
170 | return exit; | ||
171 | } | ||
172 | |||
173 | /** | ||
174 | * <!-- begin-user-doc --> | ||
175 | * <!-- end-user-doc --> | ||
176 | * @generated | ||
177 | */ | ||
178 | public FinalState createFinalState() { | ||
179 | FinalStateImpl finalState = new FinalStateImpl(); | ||
180 | return finalState; | ||
181 | } | ||
182 | |||
183 | /** | ||
184 | * <!-- begin-user-doc --> | ||
185 | * <!-- end-user-doc --> | ||
186 | * @generated | ||
187 | */ | ||
188 | public EntryType createEntryTypeFromString(EDataType eDataType, String initialValue) { | ||
189 | EntryType result = EntryType.get(initialValue); | ||
190 | if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); | ||
191 | return result; | ||
192 | } | ||
193 | |||
194 | /** | ||
195 | * <!-- begin-user-doc --> | ||
196 | * <!-- end-user-doc --> | ||
197 | * @generated | ||
198 | */ | ||
199 | public String convertEntryTypeToString(EDataType eDataType, Object instanceValue) { | ||
200 | return instanceValue == null ? null : instanceValue.toString(); | ||
201 | } | ||
202 | |||
203 | /** | ||
204 | * <!-- begin-user-doc --> | ||
205 | * <!-- end-user-doc --> | ||
206 | * @generated | ||
207 | */ | ||
208 | public YakindummPackage getYakindummPackage() { | ||
209 | return (YakindummPackage)getEPackage(); | ||
210 | } | ||
211 | |||
212 | /** | ||
213 | * <!-- begin-user-doc --> | ||
214 | * <!-- end-user-doc --> | ||
215 | * @deprecated | ||
216 | * @generated | ||
217 | */ | ||
218 | @Deprecated | ||
219 | public static YakindummPackage getPackage() { | ||
220 | return YakindummPackage.eINSTANCE; | ||
221 | } | ||
222 | |||
223 | } //YakindummFactoryImpl | ||
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummPackageImpl.java new file mode 100644 index 00000000..b95dc3ea --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/yakindumm/impl/YakindummPackageImpl.java | |||
@@ -0,0 +1,511 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl; | ||
4 | |||
5 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Choice; | ||
6 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.CompositeElement; | ||
7 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Entry; | ||
8 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.EntryType; | ||
9 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Exit; | ||
10 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.FinalState; | ||
11 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Pseudostate; | ||
12 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Region; | ||
13 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.RegularState; | ||
14 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.State; | ||
15 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Statechart; | ||
16 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Transition; | ||
17 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.Vertex; | ||
18 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummFactory; | ||
19 | import ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage; | ||
20 | |||
21 | import org.eclipse.emf.ecore.EAttribute; | ||
22 | import org.eclipse.emf.ecore.EClass; | ||
23 | import org.eclipse.emf.ecore.EEnum; | ||
24 | import org.eclipse.emf.ecore.EPackage; | ||
25 | import org.eclipse.emf.ecore.EReference; | ||
26 | |||
27 | import org.eclipse.emf.ecore.impl.EPackageImpl; | ||
28 | |||
29 | /** | ||
30 | * <!-- begin-user-doc --> | ||
31 | * An implementation of the model <b>Package</b>. | ||
32 | * <!-- end-user-doc --> | ||
33 | * @generated | ||
34 | */ | ||
35 | public class YakindummPackageImpl extends EPackageImpl implements YakindummPackage { | ||
36 | /** | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @generated | ||
40 | */ | ||
41 | private EClass pseudostateEClass = null; | ||
42 | |||
43 | /** | ||
44 | * <!-- begin-user-doc --> | ||
45 | * <!-- end-user-doc --> | ||
46 | * @generated | ||
47 | */ | ||
48 | private EClass vertexEClass = null; | ||
49 | |||
50 | /** | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @generated | ||
54 | */ | ||
55 | private EClass regionEClass = null; | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | private EClass transitionEClass = null; | ||
63 | |||
64 | /** | ||
65 | * <!-- begin-user-doc --> | ||
66 | * <!-- end-user-doc --> | ||
67 | * @generated | ||
68 | */ | ||
69 | private EClass statechartEClass = null; | ||
70 | |||
71 | /** | ||
72 | * <!-- begin-user-doc --> | ||
73 | * <!-- end-user-doc --> | ||
74 | * @generated | ||
75 | */ | ||
76 | private EClass entryEClass = null; | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | private EClass stateEClass = null; | ||
84 | |||
85 | /** | ||
86 | * <!-- begin-user-doc --> | ||
87 | * <!-- end-user-doc --> | ||
88 | * @generated | ||
89 | */ | ||
90 | private EClass regularStateEClass = null; | ||
91 | |||
92 | /** | ||
93 | * <!-- begin-user-doc --> | ||
94 | * <!-- end-user-doc --> | ||
95 | * @generated | ||
96 | */ | ||
97 | private EClass compositeElementEClass = null; | ||
98 | |||
99 | /** | ||
100 | * <!-- begin-user-doc --> | ||
101 | * <!-- end-user-doc --> | ||
102 | * @generated | ||
103 | */ | ||
104 | private EClass choiceEClass = null; | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | private EClass exitEClass = null; | ||
112 | |||
113 | /** | ||
114 | * <!-- begin-user-doc --> | ||
115 | * <!-- end-user-doc --> | ||
116 | * @generated | ||
117 | */ | ||
118 | private EClass finalStateEClass = null; | ||
119 | |||
120 | /** | ||
121 | * <!-- begin-user-doc --> | ||
122 | * <!-- end-user-doc --> | ||
123 | * @generated | ||
124 | */ | ||
125 | private EEnum entryTypeEEnum = null; | ||
126 | |||
127 | /** | ||
128 | * Creates an instance of the model <b>Package</b>, registered with | ||
129 | * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package | ||
130 | * package URI value. | ||
131 | * <p>Note: the correct way to create the package is via the static | ||
132 | * factory method {@link #init init()}, which also performs | ||
133 | * initialization of the package, or returns the registered package, | ||
134 | * if one already exists. | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @see org.eclipse.emf.ecore.EPackage.Registry | ||
138 | * @see ca.mcgill.ecse.dslreasoner.vampire.yakindumm.YakindummPackage#eNS_URI | ||
139 | * @see #init() | ||
140 | * @generated | ||
141 | */ | ||
142 | private YakindummPackageImpl() { | ||
143 | super(eNS_URI, YakindummFactory.eINSTANCE); | ||
144 | } | ||
145 | |||
146 | /** | ||
147 | * <!-- begin-user-doc --> | ||
148 | * <!-- end-user-doc --> | ||
149 | * @generated | ||
150 | */ | ||
151 | private static boolean isInited = false; | ||
152 | |||
153 | /** | ||
154 | * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. | ||
155 | * | ||
156 | * <p>This method is used to initialize {@link YakindummPackage#eINSTANCE} when that field is accessed. | ||
157 | * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. | ||
158 | * <!-- begin-user-doc --> | ||
159 | * <!-- end-user-doc --> | ||
160 | * @see #eNS_URI | ||
161 | * @see #createPackageContents() | ||
162 | * @see #initializePackageContents() | ||
163 | * @generated | ||
164 | */ | ||
165 | public static YakindummPackage init() { | ||
166 | if (isInited) return (YakindummPackage)EPackage.Registry.INSTANCE.getEPackage(YakindummPackage.eNS_URI); | ||
167 | |||
168 | // Obtain or create and register package | ||
169 | Object registeredYakindummPackage = EPackage.Registry.INSTANCE.get(eNS_URI); | ||
170 | YakindummPackageImpl theYakindummPackage = registeredYakindummPackage instanceof YakindummPackageImpl ? (YakindummPackageImpl)registeredYakindummPackage : new YakindummPackageImpl(); | ||
171 | |||
172 | isInited = true; | ||
173 | |||
174 | // Create package meta-data objects | ||
175 | theYakindummPackage.createPackageContents(); | ||
176 | |||
177 | // Initialize created meta-data | ||
178 | theYakindummPackage.initializePackageContents(); | ||
179 | |||
180 | // Mark meta-data to indicate it can't be changed | ||
181 | theYakindummPackage.freeze(); | ||
182 | |||
183 | // Update the registry and return the package | ||
184 | EPackage.Registry.INSTANCE.put(YakindummPackage.eNS_URI, theYakindummPackage); | ||
185 | return theYakindummPackage; | ||
186 | } | ||
187 | |||
188 | /** | ||
189 | * <!-- begin-user-doc --> | ||
190 | * <!-- end-user-doc --> | ||
191 | * @generated | ||
192 | */ | ||
193 | public EClass getPseudostate() { | ||
194 | return pseudostateEClass; | ||
195 | } | ||
196 | |||
197 | /** | ||
198 | * <!-- begin-user-doc --> | ||
199 | * <!-- end-user-doc --> | ||
200 | * @generated | ||
201 | */ | ||
202 | public EClass getVertex() { | ||
203 | return vertexEClass; | ||
204 | } | ||
205 | |||
206 | /** | ||
207 | * <!-- begin-user-doc --> | ||
208 | * <!-- end-user-doc --> | ||
209 | * @generated | ||
210 | */ | ||
211 | public EReference getVertex_IncomingTransitions() { | ||
212 | return (EReference)vertexEClass.getEStructuralFeatures().get(0); | ||
213 | } | ||
214 | |||
215 | /** | ||
216 | * <!-- begin-user-doc --> | ||
217 | * <!-- end-user-doc --> | ||
218 | * @generated | ||
219 | */ | ||
220 | public EReference getVertex_OutgoingTransitions() { | ||
221 | return (EReference)vertexEClass.getEStructuralFeatures().get(1); | ||
222 | } | ||
223 | |||
224 | /** | ||
225 | * <!-- begin-user-doc --> | ||
226 | * <!-- end-user-doc --> | ||
227 | * @generated | ||
228 | */ | ||
229 | public EClass getRegion() { | ||
230 | return regionEClass; | ||
231 | } | ||
232 | |||
233 | /** | ||
234 | * <!-- begin-user-doc --> | ||
235 | * <!-- end-user-doc --> | ||
236 | * @generated | ||
237 | */ | ||
238 | public EReference getRegion_Vertices() { | ||
239 | return (EReference)regionEClass.getEStructuralFeatures().get(0); | ||
240 | } | ||
241 | |||
242 | /** | ||
243 | * <!-- begin-user-doc --> | ||
244 | * <!-- end-user-doc --> | ||
245 | * @generated | ||
246 | */ | ||
247 | public EClass getTransition() { | ||
248 | return transitionEClass; | ||
249 | } | ||
250 | |||
251 | /** | ||
252 | * <!-- begin-user-doc --> | ||
253 | * <!-- end-user-doc --> | ||
254 | * @generated | ||
255 | */ | ||
256 | public EReference getTransition_Target() { | ||
257 | return (EReference)transitionEClass.getEStructuralFeatures().get(0); | ||
258 | } | ||
259 | |||
260 | /** | ||
261 | * <!-- begin-user-doc --> | ||
262 | * <!-- end-user-doc --> | ||
263 | * @generated | ||
264 | */ | ||
265 | public EReference getTransition_Source() { | ||
266 | return (EReference)transitionEClass.getEStructuralFeatures().get(1); | ||
267 | } | ||
268 | |||
269 | /** | ||
270 | * <!-- begin-user-doc --> | ||
271 | * <!-- end-user-doc --> | ||
272 | * @generated | ||
273 | */ | ||
274 | public EClass getStatechart() { | ||
275 | return statechartEClass; | ||
276 | } | ||
277 | |||
278 | /** | ||
279 | * <!-- begin-user-doc --> | ||
280 | * <!-- end-user-doc --> | ||
281 | * @generated | ||
282 | */ | ||
283 | public EClass getEntry() { | ||
284 | return entryEClass; | ||
285 | } | ||
286 | |||
287 | /** | ||
288 | * <!-- begin-user-doc --> | ||
289 | * <!-- end-user-doc --> | ||
290 | * @generated | ||
291 | */ | ||
292 | public EAttribute getEntry_Type() { | ||
293 | return (EAttribute)entryEClass.getEStructuralFeatures().get(0); | ||
294 | } | ||
295 | |||
296 | /** | ||
297 | * <!-- begin-user-doc --> | ||
298 | * <!-- end-user-doc --> | ||
299 | * @generated | ||
300 | */ | ||
301 | public EClass getState() { | ||
302 | return stateEClass; | ||
303 | } | ||
304 | |||
305 | /** | ||
306 | * <!-- begin-user-doc --> | ||
307 | * <!-- end-user-doc --> | ||
308 | * @generated | ||
309 | */ | ||
310 | public EClass getRegularState() { | ||
311 | return regularStateEClass; | ||
312 | } | ||
313 | |||
314 | /** | ||
315 | * <!-- begin-user-doc --> | ||
316 | * <!-- end-user-doc --> | ||
317 | * @generated | ||
318 | */ | ||
319 | public EClass getCompositeElement() { | ||
320 | return compositeElementEClass; | ||
321 | } | ||
322 | |||
323 | /** | ||
324 | * <!-- begin-user-doc --> | ||
325 | * <!-- end-user-doc --> | ||
326 | * @generated | ||
327 | */ | ||
328 | public EReference getCompositeElement_Regions() { | ||
329 | return (EReference)compositeElementEClass.getEStructuralFeatures().get(0); | ||
330 | } | ||
331 | |||
332 | /** | ||
333 | * <!-- begin-user-doc --> | ||
334 | * <!-- end-user-doc --> | ||
335 | * @generated | ||
336 | */ | ||
337 | public EClass getChoice() { | ||
338 | return choiceEClass; | ||
339 | } | ||
340 | |||
341 | /** | ||
342 | * <!-- begin-user-doc --> | ||
343 | * <!-- end-user-doc --> | ||
344 | * @generated | ||
345 | */ | ||
346 | public EClass getExit() { | ||
347 | return exitEClass; | ||
348 | } | ||
349 | |||
350 | /** | ||
351 | * <!-- begin-user-doc --> | ||
352 | * <!-- end-user-doc --> | ||
353 | * @generated | ||
354 | */ | ||
355 | public EClass getFinalState() { | ||
356 | return finalStateEClass; | ||
357 | } | ||
358 | |||
359 | /** | ||
360 | * <!-- begin-user-doc --> | ||
361 | * <!-- end-user-doc --> | ||
362 | * @generated | ||
363 | */ | ||
364 | public EEnum getEntryType() { | ||
365 | return entryTypeEEnum; | ||
366 | } | ||
367 | |||
368 | /** | ||
369 | * <!-- begin-user-doc --> | ||
370 | * <!-- end-user-doc --> | ||
371 | * @generated | ||
372 | */ | ||
373 | public YakindummFactory getYakindummFactory() { | ||
374 | return (YakindummFactory)getEFactoryInstance(); | ||
375 | } | ||
376 | |||
377 | /** | ||
378 | * <!-- begin-user-doc --> | ||
379 | * <!-- end-user-doc --> | ||
380 | * @generated | ||
381 | */ | ||
382 | private boolean isCreated = false; | ||
383 | |||
384 | /** | ||
385 | * Creates the meta-model objects for the package. This method is | ||
386 | * guarded to have no affect on any invocation but its first. | ||
387 | * <!-- begin-user-doc --> | ||
388 | * <!-- end-user-doc --> | ||
389 | * @generated | ||
390 | */ | ||
391 | public void createPackageContents() { | ||
392 | if (isCreated) return; | ||
393 | isCreated = true; | ||
394 | |||
395 | // Create classes and their features | ||
396 | pseudostateEClass = createEClass(PSEUDOSTATE); | ||
397 | |||
398 | vertexEClass = createEClass(VERTEX); | ||
399 | createEReference(vertexEClass, VERTEX__INCOMING_TRANSITIONS); | ||
400 | createEReference(vertexEClass, VERTEX__OUTGOING_TRANSITIONS); | ||
401 | |||
402 | regionEClass = createEClass(REGION); | ||
403 | createEReference(regionEClass, REGION__VERTICES); | ||
404 | |||
405 | transitionEClass = createEClass(TRANSITION); | ||
406 | createEReference(transitionEClass, TRANSITION__TARGET); | ||
407 | createEReference(transitionEClass, TRANSITION__SOURCE); | ||
408 | |||
409 | statechartEClass = createEClass(STATECHART); | ||
410 | |||
411 | entryEClass = createEClass(ENTRY); | ||
412 | createEAttribute(entryEClass, ENTRY__TYPE); | ||
413 | |||
414 | stateEClass = createEClass(STATE); | ||
415 | |||
416 | regularStateEClass = createEClass(REGULAR_STATE); | ||
417 | |||
418 | compositeElementEClass = createEClass(COMPOSITE_ELEMENT); | ||
419 | createEReference(compositeElementEClass, COMPOSITE_ELEMENT__REGIONS); | ||
420 | |||
421 | choiceEClass = createEClass(CHOICE); | ||
422 | |||
423 | exitEClass = createEClass(EXIT); | ||
424 | |||
425 | finalStateEClass = createEClass(FINAL_STATE); | ||
426 | |||
427 | // Create enums | ||
428 | entryTypeEEnum = createEEnum(ENTRY_TYPE); | ||
429 | } | ||
430 | |||
431 | /** | ||
432 | * <!-- begin-user-doc --> | ||
433 | * <!-- end-user-doc --> | ||
434 | * @generated | ||
435 | */ | ||
436 | private boolean isInitialized = false; | ||
437 | |||
438 | /** | ||
439 | * Complete the initialization of the package and its meta-model. This | ||
440 | * method is guarded to have no affect on any invocation but its first. | ||
441 | * <!-- begin-user-doc --> | ||
442 | * <!-- end-user-doc --> | ||
443 | * @generated | ||
444 | */ | ||
445 | public void initializePackageContents() { | ||
446 | if (isInitialized) return; | ||
447 | isInitialized = true; | ||
448 | |||
449 | // Initialize package | ||
450 | setName(eNAME); | ||
451 | setNsPrefix(eNS_PREFIX); | ||
452 | setNsURI(eNS_URI); | ||
453 | |||
454 | // Create type parameters | ||
455 | |||
456 | // Set bounds for type parameters | ||
457 | |||
458 | // Add supertypes to classes | ||
459 | pseudostateEClass.getESuperTypes().add(this.getVertex()); | ||
460 | statechartEClass.getESuperTypes().add(this.getCompositeElement()); | ||
461 | entryEClass.getESuperTypes().add(this.getPseudostate()); | ||
462 | stateEClass.getESuperTypes().add(this.getRegularState()); | ||
463 | stateEClass.getESuperTypes().add(this.getCompositeElement()); | ||
464 | regularStateEClass.getESuperTypes().add(this.getVertex()); | ||
465 | choiceEClass.getESuperTypes().add(this.getPseudostate()); | ||
466 | exitEClass.getESuperTypes().add(this.getPseudostate()); | ||
467 | finalStateEClass.getESuperTypes().add(this.getRegularState()); | ||
468 | |||
469 | // Initialize classes, features, and operations; add parameters | ||
470 | initEClass(pseudostateEClass, Pseudostate.class, "Pseudostate", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
471 | |||
472 | initEClass(vertexEClass, Vertex.class, "Vertex", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
473 | initEReference(getVertex_IncomingTransitions(), this.getTransition(), this.getTransition_Target(), "incomingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); | ||
474 | initEReference(getVertex_OutgoingTransitions(), this.getTransition(), this.getTransition_Source(), "outgoingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); | ||
475 | |||
476 | initEClass(regionEClass, Region.class, "Region", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
477 | initEReference(getRegion_Vertices(), this.getVertex(), null, "vertices", null, 0, -1, Region.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); | ||
478 | |||
479 | initEClass(transitionEClass, Transition.class, "Transition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
480 | initEReference(getTransition_Target(), this.getVertex(), this.getVertex_IncomingTransitions(), "target", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); | ||
481 | initEReference(getTransition_Source(), this.getVertex(), this.getVertex_OutgoingTransitions(), "source", null, 0, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); | ||
482 | |||
483 | initEClass(statechartEClass, Statechart.class, "Statechart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
484 | |||
485 | initEClass(entryEClass, Entry.class, "Entry", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
486 | initEAttribute(getEntry_Type(), this.getEntryType(), "Type", null, 1, 1, Entry.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
487 | |||
488 | initEClass(stateEClass, State.class, "State", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
489 | |||
490 | initEClass(regularStateEClass, RegularState.class, "RegularState", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
491 | |||
492 | initEClass(compositeElementEClass, CompositeElement.class, "CompositeElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
493 | initEReference(getCompositeElement_Regions(), this.getRegion(), null, "regions", null, 0, -1, CompositeElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
494 | |||
495 | initEClass(choiceEClass, Choice.class, "Choice", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
496 | |||
497 | initEClass(exitEClass, Exit.class, "Exit", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
498 | |||
499 | initEClass(finalStateEClass, FinalState.class, "FinalState", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
500 | |||
501 | // Initialize enums and add enum literals | ||
502 | initEEnum(entryTypeEEnum, EntryType.class, "EntryType"); | ||
503 | addEEnumLiteral(entryTypeEEnum, EntryType.NORMAL); | ||
504 | addEEnumLiteral(entryTypeEEnum, EntryType.HISTORY); | ||
505 | addEEnumLiteral(entryTypeEEnum, EntryType.DEEP_HISTORY); | ||
506 | |||
507 | // Create resource | ||
508 | createResource(eNS_URI); | ||
509 | } | ||
510 | |||
511 | } //YakindummPackageImpl | ||