diff options
Diffstat (limited to 'Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl')
16 files changed, 0 insertions, 2480 deletions
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/AndGateImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/AndGateImpl.java deleted file mode 100644 index 509843b1..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/AndGateImpl.java +++ /dev/null | |||
@@ -1,37 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.AndGate; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>And Gate</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class AndGateImpl extends GateImpl implements AndGate { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected AndGateImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return FtPackage.Literals.AND_GATE; | ||
35 | } | ||
36 | |||
37 | } //AndGateImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/BasicEventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/BasicEventImpl.java deleted file mode 100644 index bbed7b00..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/BasicEventImpl.java +++ /dev/null | |||
@@ -1,177 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.BasicEvent; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Distribution; | ||
7 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
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 | |||
17 | /** | ||
18 | * <!-- begin-user-doc --> | ||
19 | * An implementation of the model object '<em><b>Basic Event</b></em>'. | ||
20 | * <!-- end-user-doc --> | ||
21 | * <p> | ||
22 | * The following features are implemented: | ||
23 | * </p> | ||
24 | * <ul> | ||
25 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.BasicEventImpl#getDistribution <em>Distribution</em>}</li> | ||
26 | * </ul> | ||
27 | * | ||
28 | * @generated | ||
29 | */ | ||
30 | public class BasicEventImpl extends RandomEventImpl implements BasicEvent { | ||
31 | /** | ||
32 | * The cached value of the '{@link #getDistribution() <em>Distribution</em>}' containment reference. | ||
33 | * <!-- begin-user-doc --> | ||
34 | * <!-- end-user-doc --> | ||
35 | * @see #getDistribution() | ||
36 | * @generated | ||
37 | * @ordered | ||
38 | */ | ||
39 | protected Distribution distribution; | ||
40 | |||
41 | /** | ||
42 | * <!-- begin-user-doc --> | ||
43 | * <!-- end-user-doc --> | ||
44 | * @generated | ||
45 | */ | ||
46 | protected BasicEventImpl() { | ||
47 | super(); | ||
48 | } | ||
49 | |||
50 | /** | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @generated | ||
54 | */ | ||
55 | @Override | ||
56 | protected EClass eStaticClass() { | ||
57 | return FtPackage.Literals.BASIC_EVENT; | ||
58 | } | ||
59 | |||
60 | /** | ||
61 | * <!-- begin-user-doc --> | ||
62 | * <!-- end-user-doc --> | ||
63 | * @generated | ||
64 | */ | ||
65 | @Override | ||
66 | public Distribution getDistribution() { | ||
67 | return distribution; | ||
68 | } | ||
69 | |||
70 | /** | ||
71 | * <!-- begin-user-doc --> | ||
72 | * <!-- end-user-doc --> | ||
73 | * @generated | ||
74 | */ | ||
75 | public NotificationChain basicSetDistribution(Distribution newDistribution, NotificationChain msgs) { | ||
76 | Distribution oldDistribution = distribution; | ||
77 | distribution = newDistribution; | ||
78 | if (eNotificationRequired()) { | ||
79 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, FtPackage.BASIC_EVENT__DISTRIBUTION, oldDistribution, newDistribution); | ||
80 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
81 | } | ||
82 | return msgs; | ||
83 | } | ||
84 | |||
85 | /** | ||
86 | * <!-- begin-user-doc --> | ||
87 | * <!-- end-user-doc --> | ||
88 | * @generated | ||
89 | */ | ||
90 | @Override | ||
91 | public void setDistribution(Distribution newDistribution) { | ||
92 | if (newDistribution != distribution) { | ||
93 | NotificationChain msgs = null; | ||
94 | if (distribution != null) | ||
95 | msgs = ((InternalEObject)distribution).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - FtPackage.BASIC_EVENT__DISTRIBUTION, null, msgs); | ||
96 | if (newDistribution != null) | ||
97 | msgs = ((InternalEObject)newDistribution).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - FtPackage.BASIC_EVENT__DISTRIBUTION, null, msgs); | ||
98 | msgs = basicSetDistribution(newDistribution, msgs); | ||
99 | if (msgs != null) msgs.dispatch(); | ||
100 | } | ||
101 | else if (eNotificationRequired()) | ||
102 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.BASIC_EVENT__DISTRIBUTION, newDistribution, newDistribution)); | ||
103 | } | ||
104 | |||
105 | /** | ||
106 | * <!-- begin-user-doc --> | ||
107 | * <!-- end-user-doc --> | ||
108 | * @generated | ||
109 | */ | ||
110 | @Override | ||
111 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
112 | switch (featureID) { | ||
113 | case FtPackage.BASIC_EVENT__DISTRIBUTION: | ||
114 | return basicSetDistribution(null, msgs); | ||
115 | } | ||
116 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.BASIC_EVENT__DISTRIBUTION: | ||
128 | return getDistribution(); | ||
129 | } | ||
130 | return super.eGet(featureID, resolve, coreType); | ||
131 | } | ||
132 | |||
133 | /** | ||
134 | * <!-- begin-user-doc --> | ||
135 | * <!-- end-user-doc --> | ||
136 | * @generated | ||
137 | */ | ||
138 | @Override | ||
139 | public void eSet(int featureID, Object newValue) { | ||
140 | switch (featureID) { | ||
141 | case FtPackage.BASIC_EVENT__DISTRIBUTION: | ||
142 | setDistribution((Distribution)newValue); | ||
143 | return; | ||
144 | } | ||
145 | super.eSet(featureID, newValue); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public void eUnset(int featureID) { | ||
155 | switch (featureID) { | ||
156 | case FtPackage.BASIC_EVENT__DISTRIBUTION: | ||
157 | setDistribution((Distribution)null); | ||
158 | return; | ||
159 | } | ||
160 | super.eUnset(featureID); | ||
161 | } | ||
162 | |||
163 | /** | ||
164 | * <!-- begin-user-doc --> | ||
165 | * <!-- end-user-doc --> | ||
166 | * @generated | ||
167 | */ | ||
168 | @Override | ||
169 | public boolean eIsSet(int featureID) { | ||
170 | switch (featureID) { | ||
171 | case FtPackage.BASIC_EVENT__DISTRIBUTION: | ||
172 | return distribution != null; | ||
173 | } | ||
174 | return super.eIsSet(featureID); | ||
175 | } | ||
176 | |||
177 | } //BasicEventImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantDistributionImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantDistributionImpl.java deleted file mode 100644 index 7f85ed32..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantDistributionImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantDistribution; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>Constant Distribution</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.ConstantDistributionImpl#getP <em>P</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public class ConstantDistributionImpl extends DistributionImpl implements ConstantDistribution { | ||
28 | /** | ||
29 | * The default value of the '{@link #getP() <em>P</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #getP() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final double P_EDEFAULT = 0.0; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #getP() <em>P</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #getP() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected double p = P_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected ConstantDistributionImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.CONSTANT_DISTRIBUTION; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public double getP() { | ||
74 | return p; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setP(double newP) { | ||
84 | double oldP = p; | ||
85 | p = newP; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.CONSTANT_DISTRIBUTION__P, oldP, p)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.CONSTANT_DISTRIBUTION__P: | ||
99 | return getP(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.CONSTANT_DISTRIBUTION__P: | ||
113 | setP((Double)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.CONSTANT_DISTRIBUTION__P: | ||
128 | setP(P_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.CONSTANT_DISTRIBUTION__P: | ||
143 | return p != P_EDEFAULT; | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (p: "); | ||
159 | result.append(p); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //ConstantDistributionImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantEventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantEventImpl.java deleted file mode 100644 index fc7bcf09..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantEventImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantEvent; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>Constant Event</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.ConstantEventImpl#isFailed <em>Failed</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public class ConstantEventImpl extends EventImpl implements ConstantEvent { | ||
28 | /** | ||
29 | * The default value of the '{@link #isFailed() <em>Failed</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #isFailed() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final boolean FAILED_EDEFAULT = false; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #isFailed() <em>Failed</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #isFailed() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected boolean failed = FAILED_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected ConstantEventImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.CONSTANT_EVENT; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public boolean isFailed() { | ||
74 | return failed; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setFailed(boolean newFailed) { | ||
84 | boolean oldFailed = failed; | ||
85 | failed = newFailed; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.CONSTANT_EVENT__FAILED, oldFailed, failed)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.CONSTANT_EVENT__FAILED: | ||
99 | return isFailed(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.CONSTANT_EVENT__FAILED: | ||
113 | setFailed((Boolean)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.CONSTANT_EVENT__FAILED: | ||
128 | setFailed(FAILED_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.CONSTANT_EVENT__FAILED: | ||
143 | return failed != FAILED_EDEFAULT; | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (failed: "); | ||
159 | result.append(failed); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //ConstantEventImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantModelImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantModelImpl.java deleted file mode 100644 index 52e1605b..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ConstantModelImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantModel; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>Constant Model</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.ConstantModelImpl#isFailed <em>Failed</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public class ConstantModelImpl extends ReliabilityModelImpl implements ConstantModel { | ||
28 | /** | ||
29 | * The default value of the '{@link #isFailed() <em>Failed</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #isFailed() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final boolean FAILED_EDEFAULT = false; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #isFailed() <em>Failed</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #isFailed() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected boolean failed = FAILED_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected ConstantModelImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.CONSTANT_MODEL; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public boolean isFailed() { | ||
74 | return failed; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setFailed(boolean newFailed) { | ||
84 | boolean oldFailed = failed; | ||
85 | failed = newFailed; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.CONSTANT_MODEL__FAILED, oldFailed, failed)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.CONSTANT_MODEL__FAILED: | ||
99 | return isFailed(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.CONSTANT_MODEL__FAILED: | ||
113 | setFailed((Boolean)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.CONSTANT_MODEL__FAILED: | ||
128 | setFailed(FAILED_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.CONSTANT_MODEL__FAILED: | ||
143 | return failed != FAILED_EDEFAULT; | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (failed: "); | ||
159 | result.append(failed); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //ConstantModelImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/DistributionImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/DistributionImpl.java deleted file mode 100644 index 171a58cd..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/DistributionImpl.java +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Distribution; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
11 | |||
12 | /** | ||
13 | * <!-- begin-user-doc --> | ||
14 | * An implementation of the model object '<em><b>Distribution</b></em>'. | ||
15 | * <!-- end-user-doc --> | ||
16 | * | ||
17 | * @generated | ||
18 | */ | ||
19 | public abstract class DistributionImpl extends MinimalEObjectImpl.Container implements Distribution { | ||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * <!-- end-user-doc --> | ||
23 | * @generated | ||
24 | */ | ||
25 | protected DistributionImpl() { | ||
26 | super(); | ||
27 | } | ||
28 | |||
29 | /** | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @generated | ||
33 | */ | ||
34 | @Override | ||
35 | protected EClass eStaticClass() { | ||
36 | return FtPackage.Literals.DISTRIBUTION; | ||
37 | } | ||
38 | |||
39 | } //DistributionImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/EventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/EventImpl.java deleted file mode 100644 index b37fa6bd..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/EventImpl.java +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Event; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
11 | |||
12 | /** | ||
13 | * <!-- begin-user-doc --> | ||
14 | * An implementation of the model object '<em><b>Event</b></em>'. | ||
15 | * <!-- end-user-doc --> | ||
16 | * | ||
17 | * @generated | ||
18 | */ | ||
19 | public abstract class EventImpl extends MinimalEObjectImpl.Container implements Event { | ||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * <!-- end-user-doc --> | ||
23 | * @generated | ||
24 | */ | ||
25 | protected EventImpl() { | ||
26 | super(); | ||
27 | } | ||
28 | |||
29 | /** | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @generated | ||
33 | */ | ||
34 | @Override | ||
35 | protected EClass eStaticClass() { | ||
36 | return FtPackage.Literals.EVENT; | ||
37 | } | ||
38 | |||
39 | } //EventImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ExponentialDistributionImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ExponentialDistributionImpl.java deleted file mode 100644 index b3c7bd79..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ExponentialDistributionImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ExponentialDistribution; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>Exponential Distribution</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.ExponentialDistributionImpl#getLambda <em>Lambda</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public class ExponentialDistributionImpl extends DistributionImpl implements ExponentialDistribution { | ||
28 | /** | ||
29 | * The default value of the '{@link #getLambda() <em>Lambda</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #getLambda() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final double LAMBDA_EDEFAULT = 0.0; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #getLambda() <em>Lambda</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #getLambda() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected double lambda = LAMBDA_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected ExponentialDistributionImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.EXPONENTIAL_DISTRIBUTION; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public double getLambda() { | ||
74 | return lambda; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setLambda(double newLambda) { | ||
84 | double oldLambda = lambda; | ||
85 | lambda = newLambda; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.EXPONENTIAL_DISTRIBUTION__LAMBDA, oldLambda, lambda)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.EXPONENTIAL_DISTRIBUTION__LAMBDA: | ||
99 | return getLambda(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.EXPONENTIAL_DISTRIBUTION__LAMBDA: | ||
113 | setLambda((Double)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.EXPONENTIAL_DISTRIBUTION__LAMBDA: | ||
128 | setLambda(LAMBDA_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.EXPONENTIAL_DISTRIBUTION__LAMBDA: | ||
143 | return lambda != LAMBDA_EDEFAULT; | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (lambda: "); | ||
159 | result.append(lambda); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //ExponentialDistributionImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FaultTreeImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FaultTreeImpl.java deleted file mode 100644 index 23f1d056..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FaultTreeImpl.java +++ /dev/null | |||
@@ -1,216 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FaultTree; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
7 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.RandomEvent; | ||
8 | |||
9 | import java.util.Collection; | ||
10 | |||
11 | import org.eclipse.emf.common.notify.Notification; | ||
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.impl.ENotificationImpl; | ||
20 | |||
21 | import org.eclipse.emf.ecore.util.EObjectContainmentEList; | ||
22 | import org.eclipse.emf.ecore.util.InternalEList; | ||
23 | |||
24 | /** | ||
25 | * <!-- begin-user-doc --> | ||
26 | * An implementation of the model object '<em><b>Fault Tree</b></em>'. | ||
27 | * <!-- end-user-doc --> | ||
28 | * <p> | ||
29 | * The following features are implemented: | ||
30 | * </p> | ||
31 | * <ul> | ||
32 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.FaultTreeImpl#getEvents <em>Events</em>}</li> | ||
33 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.FaultTreeImpl#getTopEvent <em>Top Event</em>}</li> | ||
34 | * </ul> | ||
35 | * | ||
36 | * @generated | ||
37 | */ | ||
38 | public class FaultTreeImpl extends ReliabilityModelImpl implements FaultTree { | ||
39 | /** | ||
40 | * The cached value of the '{@link #getEvents() <em>Events</em>}' containment reference list. | ||
41 | * <!-- begin-user-doc --> | ||
42 | * <!-- end-user-doc --> | ||
43 | * @see #getEvents() | ||
44 | * @generated | ||
45 | * @ordered | ||
46 | */ | ||
47 | protected EList<RandomEvent> events; | ||
48 | |||
49 | /** | ||
50 | * The cached value of the '{@link #getTopEvent() <em>Top Event</em>}' reference. | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @see #getTopEvent() | ||
54 | * @generated | ||
55 | * @ordered | ||
56 | */ | ||
57 | protected RandomEvent topEvent; | ||
58 | |||
59 | /** | ||
60 | * <!-- begin-user-doc --> | ||
61 | * <!-- end-user-doc --> | ||
62 | * @generated | ||
63 | */ | ||
64 | protected FaultTreeImpl() { | ||
65 | super(); | ||
66 | } | ||
67 | |||
68 | /** | ||
69 | * <!-- begin-user-doc --> | ||
70 | * <!-- end-user-doc --> | ||
71 | * @generated | ||
72 | */ | ||
73 | @Override | ||
74 | protected EClass eStaticClass() { | ||
75 | return FtPackage.Literals.FAULT_TREE; | ||
76 | } | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | @Override | ||
84 | public EList<RandomEvent> getEvents() { | ||
85 | if (events == null) { | ||
86 | events = new EObjectContainmentEList<RandomEvent>(RandomEvent.class, this, FtPackage.FAULT_TREE__EVENTS); | ||
87 | } | ||
88 | return events; | ||
89 | } | ||
90 | |||
91 | /** | ||
92 | * <!-- begin-user-doc --> | ||
93 | * <!-- end-user-doc --> | ||
94 | * @generated | ||
95 | */ | ||
96 | @Override | ||
97 | public RandomEvent getTopEvent() { | ||
98 | if (topEvent != null && topEvent.eIsProxy()) { | ||
99 | InternalEObject oldTopEvent = (InternalEObject)topEvent; | ||
100 | topEvent = (RandomEvent)eResolveProxy(oldTopEvent); | ||
101 | if (topEvent != oldTopEvent) { | ||
102 | if (eNotificationRequired()) | ||
103 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, FtPackage.FAULT_TREE__TOP_EVENT, oldTopEvent, topEvent)); | ||
104 | } | ||
105 | } | ||
106 | return topEvent; | ||
107 | } | ||
108 | |||
109 | /** | ||
110 | * <!-- begin-user-doc --> | ||
111 | * <!-- end-user-doc --> | ||
112 | * @generated | ||
113 | */ | ||
114 | public RandomEvent basicGetTopEvent() { | ||
115 | return topEvent; | ||
116 | } | ||
117 | |||
118 | /** | ||
119 | * <!-- begin-user-doc --> | ||
120 | * <!-- end-user-doc --> | ||
121 | * @generated | ||
122 | */ | ||
123 | @Override | ||
124 | public void setTopEvent(RandomEvent newTopEvent) { | ||
125 | RandomEvent oldTopEvent = topEvent; | ||
126 | topEvent = newTopEvent; | ||
127 | if (eNotificationRequired()) | ||
128 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.FAULT_TREE__TOP_EVENT, oldTopEvent, topEvent)); | ||
129 | } | ||
130 | |||
131 | /** | ||
132 | * <!-- begin-user-doc --> | ||
133 | * <!-- end-user-doc --> | ||
134 | * @generated | ||
135 | */ | ||
136 | @Override | ||
137 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
138 | switch (featureID) { | ||
139 | case FtPackage.FAULT_TREE__EVENTS: | ||
140 | return ((InternalEList<?>)getEvents()).basicRemove(otherEnd, msgs); | ||
141 | } | ||
142 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
143 | } | ||
144 | |||
145 | /** | ||
146 | * <!-- begin-user-doc --> | ||
147 | * <!-- end-user-doc --> | ||
148 | * @generated | ||
149 | */ | ||
150 | @Override | ||
151 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
152 | switch (featureID) { | ||
153 | case FtPackage.FAULT_TREE__EVENTS: | ||
154 | return getEvents(); | ||
155 | case FtPackage.FAULT_TREE__TOP_EVENT: | ||
156 | if (resolve) return getTopEvent(); | ||
157 | return basicGetTopEvent(); | ||
158 | } | ||
159 | return super.eGet(featureID, resolve, coreType); | ||
160 | } | ||
161 | |||
162 | /** | ||
163 | * <!-- begin-user-doc --> | ||
164 | * <!-- end-user-doc --> | ||
165 | * @generated | ||
166 | */ | ||
167 | @SuppressWarnings("unchecked") | ||
168 | @Override | ||
169 | public void eSet(int featureID, Object newValue) { | ||
170 | switch (featureID) { | ||
171 | case FtPackage.FAULT_TREE__EVENTS: | ||
172 | getEvents().clear(); | ||
173 | getEvents().addAll((Collection<? extends RandomEvent>)newValue); | ||
174 | return; | ||
175 | case FtPackage.FAULT_TREE__TOP_EVENT: | ||
176 | setTopEvent((RandomEvent)newValue); | ||
177 | return; | ||
178 | } | ||
179 | super.eSet(featureID, newValue); | ||
180 | } | ||
181 | |||
182 | /** | ||
183 | * <!-- begin-user-doc --> | ||
184 | * <!-- end-user-doc --> | ||
185 | * @generated | ||
186 | */ | ||
187 | @Override | ||
188 | public void eUnset(int featureID) { | ||
189 | switch (featureID) { | ||
190 | case FtPackage.FAULT_TREE__EVENTS: | ||
191 | getEvents().clear(); | ||
192 | return; | ||
193 | case FtPackage.FAULT_TREE__TOP_EVENT: | ||
194 | setTopEvent((RandomEvent)null); | ||
195 | return; | ||
196 | } | ||
197 | super.eUnset(featureID); | ||
198 | } | ||
199 | |||
200 | /** | ||
201 | * <!-- begin-user-doc --> | ||
202 | * <!-- end-user-doc --> | ||
203 | * @generated | ||
204 | */ | ||
205 | @Override | ||
206 | public boolean eIsSet(int featureID) { | ||
207 | switch (featureID) { | ||
208 | case FtPackage.FAULT_TREE__EVENTS: | ||
209 | return events != null && !events.isEmpty(); | ||
210 | case FtPackage.FAULT_TREE__TOP_EVENT: | ||
211 | return topEvent != null; | ||
212 | } | ||
213 | return super.eIsSet(featureID); | ||
214 | } | ||
215 | |||
216 | } //FaultTreeImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtFactoryImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtFactoryImpl.java deleted file mode 100644 index 126abed8..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtFactoryImpl.java +++ /dev/null | |||
@@ -1,193 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.*; | ||
6 | |||
7 | import org.eclipse.emf.ecore.EClass; | ||
8 | import org.eclipse.emf.ecore.EObject; | ||
9 | import org.eclipse.emf.ecore.EPackage; | ||
10 | |||
11 | import org.eclipse.emf.ecore.impl.EFactoryImpl; | ||
12 | |||
13 | import org.eclipse.emf.ecore.plugin.EcorePlugin; | ||
14 | |||
15 | /** | ||
16 | * <!-- begin-user-doc --> | ||
17 | * An implementation of the model <b>Factory</b>. | ||
18 | * <!-- end-user-doc --> | ||
19 | * @generated | ||
20 | */ | ||
21 | public class FtFactoryImpl extends EFactoryImpl implements FtFactory { | ||
22 | /** | ||
23 | * Creates the default factory implementation. | ||
24 | * <!-- begin-user-doc --> | ||
25 | * <!-- end-user-doc --> | ||
26 | * @generated | ||
27 | */ | ||
28 | public static FtFactory init() { | ||
29 | try { | ||
30 | FtFactory theFtFactory = (FtFactory)EPackage.Registry.INSTANCE.getEFactory(FtPackage.eNS_URI); | ||
31 | if (theFtFactory != null) { | ||
32 | return theFtFactory; | ||
33 | } | ||
34 | } | ||
35 | catch (Exception exception) { | ||
36 | EcorePlugin.INSTANCE.log(exception); | ||
37 | } | ||
38 | return new FtFactoryImpl(); | ||
39 | } | ||
40 | |||
41 | /** | ||
42 | * Creates an instance of the factory. | ||
43 | * <!-- begin-user-doc --> | ||
44 | * <!-- end-user-doc --> | ||
45 | * @generated | ||
46 | */ | ||
47 | public FtFactoryImpl() { | ||
48 | super(); | ||
49 | } | ||
50 | |||
51 | /** | ||
52 | * <!-- begin-user-doc --> | ||
53 | * <!-- end-user-doc --> | ||
54 | * @generated | ||
55 | */ | ||
56 | @Override | ||
57 | public EObject create(EClass eClass) { | ||
58 | switch (eClass.getClassifierID()) { | ||
59 | case FtPackage.FAULT_TREE: return createFaultTree(); | ||
60 | case FtPackage.BASIC_EVENT: return createBasicEvent(); | ||
61 | case FtPackage.CONSTANT_DISTRIBUTION: return createConstantDistribution(); | ||
62 | case FtPackage.EXPONENTIAL_DISTRIBUTION: return createExponentialDistribution(); | ||
63 | case FtPackage.AND_GATE: return createAndGate(); | ||
64 | case FtPackage.OR_GATE: return createOrGate(); | ||
65 | case FtPackage.KOF_MGATE: return createKOfMGate(); | ||
66 | case FtPackage.CONSTANT_MODEL: return createConstantModel(); | ||
67 | case FtPackage.CONSTANT_EVENT: return createConstantEvent(); | ||
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 FaultTree createFaultTree() { | ||
80 | FaultTreeImpl faultTree = new FaultTreeImpl(); | ||
81 | return faultTree; | ||
82 | } | ||
83 | |||
84 | /** | ||
85 | * <!-- begin-user-doc --> | ||
86 | * <!-- end-user-doc --> | ||
87 | * @generated | ||
88 | */ | ||
89 | @Override | ||
90 | public BasicEvent createBasicEvent() { | ||
91 | BasicEventImpl basicEvent = new BasicEventImpl(); | ||
92 | return basicEvent; | ||
93 | } | ||
94 | |||
95 | /** | ||
96 | * <!-- begin-user-doc --> | ||
97 | * <!-- end-user-doc --> | ||
98 | * @generated | ||
99 | */ | ||
100 | @Override | ||
101 | public ConstantDistribution createConstantDistribution() { | ||
102 | ConstantDistributionImpl constantDistribution = new ConstantDistributionImpl(); | ||
103 | return constantDistribution; | ||
104 | } | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | @Override | ||
112 | public ExponentialDistribution createExponentialDistribution() { | ||
113 | ExponentialDistributionImpl exponentialDistribution = new ExponentialDistributionImpl(); | ||
114 | return exponentialDistribution; | ||
115 | } | ||
116 | |||
117 | /** | ||
118 | * <!-- begin-user-doc --> | ||
119 | * <!-- end-user-doc --> | ||
120 | * @generated | ||
121 | */ | ||
122 | @Override | ||
123 | public AndGate createAndGate() { | ||
124 | AndGateImpl andGate = new AndGateImpl(); | ||
125 | return andGate; | ||
126 | } | ||
127 | |||
128 | /** | ||
129 | * <!-- begin-user-doc --> | ||
130 | * <!-- end-user-doc --> | ||
131 | * @generated | ||
132 | */ | ||
133 | @Override | ||
134 | public OrGate createOrGate() { | ||
135 | OrGateImpl orGate = new OrGateImpl(); | ||
136 | return orGate; | ||
137 | } | ||
138 | |||
139 | /** | ||
140 | * <!-- begin-user-doc --> | ||
141 | * <!-- end-user-doc --> | ||
142 | * @generated | ||
143 | */ | ||
144 | @Override | ||
145 | public KOfMGate createKOfMGate() { | ||
146 | KOfMGateImpl kOfMGate = new KOfMGateImpl(); | ||
147 | return kOfMGate; | ||
148 | } | ||
149 | |||
150 | /** | ||
151 | * <!-- begin-user-doc --> | ||
152 | * <!-- end-user-doc --> | ||
153 | * @generated | ||
154 | */ | ||
155 | @Override | ||
156 | public ConstantModel createConstantModel() { | ||
157 | ConstantModelImpl constantModel = new ConstantModelImpl(); | ||
158 | return constantModel; | ||
159 | } | ||
160 | |||
161 | /** | ||
162 | * <!-- begin-user-doc --> | ||
163 | * <!-- end-user-doc --> | ||
164 | * @generated | ||
165 | */ | ||
166 | @Override | ||
167 | public ConstantEvent createConstantEvent() { | ||
168 | ConstantEventImpl constantEvent = new ConstantEventImpl(); | ||
169 | return constantEvent; | ||
170 | } | ||
171 | |||
172 | /** | ||
173 | * <!-- begin-user-doc --> | ||
174 | * <!-- end-user-doc --> | ||
175 | * @generated | ||
176 | */ | ||
177 | @Override | ||
178 | public FtPackage getFtPackage() { | ||
179 | return (FtPackage)getEPackage(); | ||
180 | } | ||
181 | |||
182 | /** | ||
183 | * <!-- begin-user-doc --> | ||
184 | * <!-- end-user-doc --> | ||
185 | * @deprecated | ||
186 | * @generated | ||
187 | */ | ||
188 | @Deprecated | ||
189 | public static FtPackage getPackage() { | ||
190 | return FtPackage.eINSTANCE; | ||
191 | } | ||
192 | |||
193 | } //FtFactoryImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtPackageImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtPackageImpl.java deleted file mode 100644 index cc2c0617..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/FtPackageImpl.java +++ /dev/null | |||
@@ -1,586 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.AndGate; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.BasicEvent; | ||
7 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantDistribution; | ||
8 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantEvent; | ||
9 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ConstantModel; | ||
10 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Distribution; | ||
11 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Event; | ||
12 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ExponentialDistribution; | ||
13 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FaultTree; | ||
14 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtFactory; | ||
15 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
16 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Gate; | ||
17 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.KOfMGate; | ||
18 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.OrGate; | ||
19 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.RandomEvent; | ||
20 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ReliabilityModel; | ||
21 | |||
22 | import org.eclipse.emf.ecore.EAttribute; | ||
23 | import org.eclipse.emf.ecore.EClass; | ||
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 FtPackageImpl extends EPackageImpl implements FtPackage { | ||
36 | /** | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @generated | ||
40 | */ | ||
41 | private EClass faultTreeEClass = null; | ||
42 | |||
43 | /** | ||
44 | * <!-- begin-user-doc --> | ||
45 | * <!-- end-user-doc --> | ||
46 | * @generated | ||
47 | */ | ||
48 | private EClass randomEventEClass = null; | ||
49 | |||
50 | /** | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @generated | ||
54 | */ | ||
55 | private EClass basicEventEClass = null; | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | private EClass gateEClass = null; | ||
63 | |||
64 | /** | ||
65 | * <!-- begin-user-doc --> | ||
66 | * <!-- end-user-doc --> | ||
67 | * @generated | ||
68 | */ | ||
69 | private EClass distributionEClass = null; | ||
70 | |||
71 | /** | ||
72 | * <!-- begin-user-doc --> | ||
73 | * <!-- end-user-doc --> | ||
74 | * @generated | ||
75 | */ | ||
76 | private EClass constantDistributionEClass = null; | ||
77 | |||
78 | /** | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @generated | ||
82 | */ | ||
83 | private EClass exponentialDistributionEClass = null; | ||
84 | |||
85 | /** | ||
86 | * <!-- begin-user-doc --> | ||
87 | * <!-- end-user-doc --> | ||
88 | * @generated | ||
89 | */ | ||
90 | private EClass andGateEClass = null; | ||
91 | |||
92 | /** | ||
93 | * <!-- begin-user-doc --> | ||
94 | * <!-- end-user-doc --> | ||
95 | * @generated | ||
96 | */ | ||
97 | private EClass orGateEClass = null; | ||
98 | |||
99 | /** | ||
100 | * <!-- begin-user-doc --> | ||
101 | * <!-- end-user-doc --> | ||
102 | * @generated | ||
103 | */ | ||
104 | private EClass kOfMGateEClass = null; | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | private EClass reliabilityModelEClass = null; | ||
112 | |||
113 | /** | ||
114 | * <!-- begin-user-doc --> | ||
115 | * <!-- end-user-doc --> | ||
116 | * @generated | ||
117 | */ | ||
118 | private EClass constantModelEClass = null; | ||
119 | |||
120 | /** | ||
121 | * <!-- begin-user-doc --> | ||
122 | * <!-- end-user-doc --> | ||
123 | * @generated | ||
124 | */ | ||
125 | private EClass eventEClass = null; | ||
126 | |||
127 | /** | ||
128 | * <!-- begin-user-doc --> | ||
129 | * <!-- end-user-doc --> | ||
130 | * @generated | ||
131 | */ | ||
132 | private EClass constantEventEClass = null; | ||
133 | |||
134 | /** | ||
135 | * Creates an instance of the model <b>Package</b>, registered with | ||
136 | * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package | ||
137 | * package URI value. | ||
138 | * <p>Note: the correct way to create the package is via the static | ||
139 | * factory method {@link #init init()}, which also performs | ||
140 | * initialization of the package, or returns the registered package, | ||
141 | * if one already exists. | ||
142 | * <!-- begin-user-doc --> | ||
143 | * <!-- end-user-doc --> | ||
144 | * @see org.eclipse.emf.ecore.EPackage.Registry | ||
145 | * @see hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage#eNS_URI | ||
146 | * @see #init() | ||
147 | * @generated | ||
148 | */ | ||
149 | private FtPackageImpl() { | ||
150 | super(eNS_URI, FtFactory.eINSTANCE); | ||
151 | } | ||
152 | |||
153 | /** | ||
154 | * <!-- begin-user-doc --> | ||
155 | * <!-- end-user-doc --> | ||
156 | * @generated | ||
157 | */ | ||
158 | private static boolean isInited = false; | ||
159 | |||
160 | /** | ||
161 | * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. | ||
162 | * | ||
163 | * <p>This method is used to initialize {@link FtPackage#eINSTANCE} when that field is accessed. | ||
164 | * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. | ||
165 | * <!-- begin-user-doc --> | ||
166 | * <!-- end-user-doc --> | ||
167 | * @see #eNS_URI | ||
168 | * @see #createPackageContents() | ||
169 | * @see #initializePackageContents() | ||
170 | * @generated | ||
171 | */ | ||
172 | public static FtPackage init() { | ||
173 | if (isInited) return (FtPackage)EPackage.Registry.INSTANCE.getEPackage(FtPackage.eNS_URI); | ||
174 | |||
175 | // Obtain or create and register package | ||
176 | Object registeredFtPackage = EPackage.Registry.INSTANCE.get(eNS_URI); | ||
177 | FtPackageImpl theFtPackage = registeredFtPackage instanceof FtPackageImpl ? (FtPackageImpl)registeredFtPackage : new FtPackageImpl(); | ||
178 | |||
179 | isInited = true; | ||
180 | |||
181 | // Create package meta-data objects | ||
182 | theFtPackage.createPackageContents(); | ||
183 | |||
184 | // Initialize created meta-data | ||
185 | theFtPackage.initializePackageContents(); | ||
186 | |||
187 | // Mark meta-data to indicate it can't be changed | ||
188 | theFtPackage.freeze(); | ||
189 | |||
190 | // Update the registry and return the package | ||
191 | EPackage.Registry.INSTANCE.put(FtPackage.eNS_URI, theFtPackage); | ||
192 | return theFtPackage; | ||
193 | } | ||
194 | |||
195 | /** | ||
196 | * <!-- begin-user-doc --> | ||
197 | * <!-- end-user-doc --> | ||
198 | * @generated | ||
199 | */ | ||
200 | @Override | ||
201 | public EClass getFaultTree() { | ||
202 | return faultTreeEClass; | ||
203 | } | ||
204 | |||
205 | /** | ||
206 | * <!-- begin-user-doc --> | ||
207 | * <!-- end-user-doc --> | ||
208 | * @generated | ||
209 | */ | ||
210 | @Override | ||
211 | public EReference getFaultTree_Events() { | ||
212 | return (EReference)faultTreeEClass.getEStructuralFeatures().get(0); | ||
213 | } | ||
214 | |||
215 | /** | ||
216 | * <!-- begin-user-doc --> | ||
217 | * <!-- end-user-doc --> | ||
218 | * @generated | ||
219 | */ | ||
220 | @Override | ||
221 | public EReference getFaultTree_TopEvent() { | ||
222 | return (EReference)faultTreeEClass.getEStructuralFeatures().get(1); | ||
223 | } | ||
224 | |||
225 | /** | ||
226 | * <!-- begin-user-doc --> | ||
227 | * <!-- end-user-doc --> | ||
228 | * @generated | ||
229 | */ | ||
230 | @Override | ||
231 | public EClass getRandomEvent() { | ||
232 | return randomEventEClass; | ||
233 | } | ||
234 | |||
235 | /** | ||
236 | * <!-- begin-user-doc --> | ||
237 | * <!-- end-user-doc --> | ||
238 | * @generated | ||
239 | */ | ||
240 | @Override | ||
241 | public EAttribute getRandomEvent_Name() { | ||
242 | return (EAttribute)randomEventEClass.getEStructuralFeatures().get(0); | ||
243 | } | ||
244 | |||
245 | /** | ||
246 | * <!-- begin-user-doc --> | ||
247 | * <!-- end-user-doc --> | ||
248 | * @generated | ||
249 | */ | ||
250 | @Override | ||
251 | public EClass getBasicEvent() { | ||
252 | return basicEventEClass; | ||
253 | } | ||
254 | |||
255 | /** | ||
256 | * <!-- begin-user-doc --> | ||
257 | * <!-- end-user-doc --> | ||
258 | * @generated | ||
259 | */ | ||
260 | @Override | ||
261 | public EReference getBasicEvent_Distribution() { | ||
262 | return (EReference)basicEventEClass.getEStructuralFeatures().get(0); | ||
263 | } | ||
264 | |||
265 | /** | ||
266 | * <!-- begin-user-doc --> | ||
267 | * <!-- end-user-doc --> | ||
268 | * @generated | ||
269 | */ | ||
270 | @Override | ||
271 | public EClass getGate() { | ||
272 | return gateEClass; | ||
273 | } | ||
274 | |||
275 | /** | ||
276 | * <!-- begin-user-doc --> | ||
277 | * <!-- end-user-doc --> | ||
278 | * @generated | ||
279 | */ | ||
280 | @Override | ||
281 | public EReference getGate_InputEvents() { | ||
282 | return (EReference)gateEClass.getEStructuralFeatures().get(0); | ||
283 | } | ||
284 | |||
285 | /** | ||
286 | * <!-- begin-user-doc --> | ||
287 | * <!-- end-user-doc --> | ||
288 | * @generated | ||
289 | */ | ||
290 | @Override | ||
291 | public EClass getDistribution() { | ||
292 | return distributionEClass; | ||
293 | } | ||
294 | |||
295 | /** | ||
296 | * <!-- begin-user-doc --> | ||
297 | * <!-- end-user-doc --> | ||
298 | * @generated | ||
299 | */ | ||
300 | @Override | ||
301 | public EClass getConstantDistribution() { | ||
302 | return constantDistributionEClass; | ||
303 | } | ||
304 | |||
305 | /** | ||
306 | * <!-- begin-user-doc --> | ||
307 | * <!-- end-user-doc --> | ||
308 | * @generated | ||
309 | */ | ||
310 | @Override | ||
311 | public EAttribute getConstantDistribution_P() { | ||
312 | return (EAttribute)constantDistributionEClass.getEStructuralFeatures().get(0); | ||
313 | } | ||
314 | |||
315 | /** | ||
316 | * <!-- begin-user-doc --> | ||
317 | * <!-- end-user-doc --> | ||
318 | * @generated | ||
319 | */ | ||
320 | @Override | ||
321 | public EClass getExponentialDistribution() { | ||
322 | return exponentialDistributionEClass; | ||
323 | } | ||
324 | |||
325 | /** | ||
326 | * <!-- begin-user-doc --> | ||
327 | * <!-- end-user-doc --> | ||
328 | * @generated | ||
329 | */ | ||
330 | @Override | ||
331 | public EAttribute getExponentialDistribution_Lambda() { | ||
332 | return (EAttribute)exponentialDistributionEClass.getEStructuralFeatures().get(0); | ||
333 | } | ||
334 | |||
335 | /** | ||
336 | * <!-- begin-user-doc --> | ||
337 | * <!-- end-user-doc --> | ||
338 | * @generated | ||
339 | */ | ||
340 | @Override | ||
341 | public EClass getAndGate() { | ||
342 | return andGateEClass; | ||
343 | } | ||
344 | |||
345 | /** | ||
346 | * <!-- begin-user-doc --> | ||
347 | * <!-- end-user-doc --> | ||
348 | * @generated | ||
349 | */ | ||
350 | @Override | ||
351 | public EClass getOrGate() { | ||
352 | return orGateEClass; | ||
353 | } | ||
354 | |||
355 | /** | ||
356 | * <!-- begin-user-doc --> | ||
357 | * <!-- end-user-doc --> | ||
358 | * @generated | ||
359 | */ | ||
360 | @Override | ||
361 | public EClass getKOfMGate() { | ||
362 | return kOfMGateEClass; | ||
363 | } | ||
364 | |||
365 | /** | ||
366 | * <!-- begin-user-doc --> | ||
367 | * <!-- end-user-doc --> | ||
368 | * @generated | ||
369 | */ | ||
370 | @Override | ||
371 | public EAttribute getKOfMGate_K() { | ||
372 | return (EAttribute)kOfMGateEClass.getEStructuralFeatures().get(0); | ||
373 | } | ||
374 | |||
375 | /** | ||
376 | * <!-- begin-user-doc --> | ||
377 | * <!-- end-user-doc --> | ||
378 | * @generated | ||
379 | */ | ||
380 | @Override | ||
381 | public EClass getReliabilityModel() { | ||
382 | return reliabilityModelEClass; | ||
383 | } | ||
384 | |||
385 | /** | ||
386 | * <!-- begin-user-doc --> | ||
387 | * <!-- end-user-doc --> | ||
388 | * @generated | ||
389 | */ | ||
390 | @Override | ||
391 | public EClass getConstantModel() { | ||
392 | return constantModelEClass; | ||
393 | } | ||
394 | |||
395 | /** | ||
396 | * <!-- begin-user-doc --> | ||
397 | * <!-- end-user-doc --> | ||
398 | * @generated | ||
399 | */ | ||
400 | @Override | ||
401 | public EAttribute getConstantModel_Failed() { | ||
402 | return (EAttribute)constantModelEClass.getEStructuralFeatures().get(0); | ||
403 | } | ||
404 | |||
405 | /** | ||
406 | * <!-- begin-user-doc --> | ||
407 | * <!-- end-user-doc --> | ||
408 | * @generated | ||
409 | */ | ||
410 | @Override | ||
411 | public EClass getEvent() { | ||
412 | return eventEClass; | ||
413 | } | ||
414 | |||
415 | /** | ||
416 | * <!-- begin-user-doc --> | ||
417 | * <!-- end-user-doc --> | ||
418 | * @generated | ||
419 | */ | ||
420 | @Override | ||
421 | public EClass getConstantEvent() { | ||
422 | return constantEventEClass; | ||
423 | } | ||
424 | |||
425 | /** | ||
426 | * <!-- begin-user-doc --> | ||
427 | * <!-- end-user-doc --> | ||
428 | * @generated | ||
429 | */ | ||
430 | @Override | ||
431 | public EAttribute getConstantEvent_Failed() { | ||
432 | return (EAttribute)constantEventEClass.getEStructuralFeatures().get(0); | ||
433 | } | ||
434 | |||
435 | /** | ||
436 | * <!-- begin-user-doc --> | ||
437 | * <!-- end-user-doc --> | ||
438 | * @generated | ||
439 | */ | ||
440 | @Override | ||
441 | public FtFactory getFtFactory() { | ||
442 | return (FtFactory)getEFactoryInstance(); | ||
443 | } | ||
444 | |||
445 | /** | ||
446 | * <!-- begin-user-doc --> | ||
447 | * <!-- end-user-doc --> | ||
448 | * @generated | ||
449 | */ | ||
450 | private boolean isCreated = false; | ||
451 | |||
452 | /** | ||
453 | * Creates the meta-model objects for the package. This method is | ||
454 | * guarded to have no affect on any invocation but its first. | ||
455 | * <!-- begin-user-doc --> | ||
456 | * <!-- end-user-doc --> | ||
457 | * @generated | ||
458 | */ | ||
459 | public void createPackageContents() { | ||
460 | if (isCreated) return; | ||
461 | isCreated = true; | ||
462 | |||
463 | // Create classes and their features | ||
464 | faultTreeEClass = createEClass(FAULT_TREE); | ||
465 | createEReference(faultTreeEClass, FAULT_TREE__EVENTS); | ||
466 | createEReference(faultTreeEClass, FAULT_TREE__TOP_EVENT); | ||
467 | |||
468 | randomEventEClass = createEClass(RANDOM_EVENT); | ||
469 | createEAttribute(randomEventEClass, RANDOM_EVENT__NAME); | ||
470 | |||
471 | basicEventEClass = createEClass(BASIC_EVENT); | ||
472 | createEReference(basicEventEClass, BASIC_EVENT__DISTRIBUTION); | ||
473 | |||
474 | gateEClass = createEClass(GATE); | ||
475 | createEReference(gateEClass, GATE__INPUT_EVENTS); | ||
476 | |||
477 | distributionEClass = createEClass(DISTRIBUTION); | ||
478 | |||
479 | constantDistributionEClass = createEClass(CONSTANT_DISTRIBUTION); | ||
480 | createEAttribute(constantDistributionEClass, CONSTANT_DISTRIBUTION__P); | ||
481 | |||
482 | exponentialDistributionEClass = createEClass(EXPONENTIAL_DISTRIBUTION); | ||
483 | createEAttribute(exponentialDistributionEClass, EXPONENTIAL_DISTRIBUTION__LAMBDA); | ||
484 | |||
485 | andGateEClass = createEClass(AND_GATE); | ||
486 | |||
487 | orGateEClass = createEClass(OR_GATE); | ||
488 | |||
489 | kOfMGateEClass = createEClass(KOF_MGATE); | ||
490 | createEAttribute(kOfMGateEClass, KOF_MGATE__K); | ||
491 | |||
492 | reliabilityModelEClass = createEClass(RELIABILITY_MODEL); | ||
493 | |||
494 | constantModelEClass = createEClass(CONSTANT_MODEL); | ||
495 | createEAttribute(constantModelEClass, CONSTANT_MODEL__FAILED); | ||
496 | |||
497 | eventEClass = createEClass(EVENT); | ||
498 | |||
499 | constantEventEClass = createEClass(CONSTANT_EVENT); | ||
500 | createEAttribute(constantEventEClass, CONSTANT_EVENT__FAILED); | ||
501 | } | ||
502 | |||
503 | /** | ||
504 | * <!-- begin-user-doc --> | ||
505 | * <!-- end-user-doc --> | ||
506 | * @generated | ||
507 | */ | ||
508 | private boolean isInitialized = false; | ||
509 | |||
510 | /** | ||
511 | * Complete the initialization of the package and its meta-model. This | ||
512 | * method is guarded to have no affect on any invocation but its first. | ||
513 | * <!-- begin-user-doc --> | ||
514 | * <!-- end-user-doc --> | ||
515 | * @generated | ||
516 | */ | ||
517 | public void initializePackageContents() { | ||
518 | if (isInitialized) return; | ||
519 | isInitialized = true; | ||
520 | |||
521 | // Initialize package | ||
522 | setName(eNAME); | ||
523 | setNsPrefix(eNS_PREFIX); | ||
524 | setNsURI(eNS_URI); | ||
525 | |||
526 | // Create type parameters | ||
527 | |||
528 | // Set bounds for type parameters | ||
529 | |||
530 | // Add supertypes to classes | ||
531 | faultTreeEClass.getESuperTypes().add(this.getReliabilityModel()); | ||
532 | randomEventEClass.getESuperTypes().add(this.getEvent()); | ||
533 | basicEventEClass.getESuperTypes().add(this.getRandomEvent()); | ||
534 | gateEClass.getESuperTypes().add(this.getRandomEvent()); | ||
535 | constantDistributionEClass.getESuperTypes().add(this.getDistribution()); | ||
536 | exponentialDistributionEClass.getESuperTypes().add(this.getDistribution()); | ||
537 | andGateEClass.getESuperTypes().add(this.getGate()); | ||
538 | orGateEClass.getESuperTypes().add(this.getGate()); | ||
539 | kOfMGateEClass.getESuperTypes().add(this.getGate()); | ||
540 | constantModelEClass.getESuperTypes().add(this.getReliabilityModel()); | ||
541 | constantEventEClass.getESuperTypes().add(this.getEvent()); | ||
542 | |||
543 | // Initialize classes, features, and operations; add parameters | ||
544 | initEClass(faultTreeEClass, FaultTree.class, "FaultTree", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
545 | initEReference(getFaultTree_Events(), this.getRandomEvent(), null, "events", null, 0, -1, FaultTree.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
546 | initEReference(getFaultTree_TopEvent(), this.getRandomEvent(), null, "topEvent", null, 1, 1, FaultTree.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
547 | |||
548 | initEClass(randomEventEClass, RandomEvent.class, "RandomEvent", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
549 | initEAttribute(getRandomEvent_Name(), ecorePackage.getEString(), "name", null, 0, 1, RandomEvent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
550 | |||
551 | initEClass(basicEventEClass, BasicEvent.class, "BasicEvent", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
552 | initEReference(getBasicEvent_Distribution(), this.getDistribution(), null, "distribution", null, 1, 1, BasicEvent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
553 | |||
554 | initEClass(gateEClass, Gate.class, "Gate", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
555 | initEReference(getGate_InputEvents(), this.getRandomEvent(), null, "inputEvents", null, 2, -1, Gate.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
556 | |||
557 | initEClass(distributionEClass, Distribution.class, "Distribution", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
558 | |||
559 | initEClass(constantDistributionEClass, ConstantDistribution.class, "ConstantDistribution", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
560 | initEAttribute(getConstantDistribution_P(), ecorePackage.getEDouble(), "p", null, 0, 1, ConstantDistribution.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
561 | |||
562 | initEClass(exponentialDistributionEClass, ExponentialDistribution.class, "ExponentialDistribution", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
563 | initEAttribute(getExponentialDistribution_Lambda(), ecorePackage.getEDouble(), "lambda", null, 0, 1, ExponentialDistribution.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
564 | |||
565 | initEClass(andGateEClass, AndGate.class, "AndGate", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
566 | |||
567 | initEClass(orGateEClass, OrGate.class, "OrGate", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
568 | |||
569 | initEClass(kOfMGateEClass, KOfMGate.class, "KOfMGate", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
570 | initEAttribute(getKOfMGate_K(), ecorePackage.getEInt(), "k", null, 0, 1, KOfMGate.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
571 | |||
572 | initEClass(reliabilityModelEClass, ReliabilityModel.class, "ReliabilityModel", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
573 | |||
574 | initEClass(constantModelEClass, ConstantModel.class, "ConstantModel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
575 | initEAttribute(getConstantModel_Failed(), ecorePackage.getEBoolean(), "failed", null, 0, 1, ConstantModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
576 | |||
577 | initEClass(eventEClass, Event.class, "Event", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
578 | |||
579 | initEClass(constantEventEClass, ConstantEvent.class, "ConstantEvent", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | ||
580 | initEAttribute(getConstantEvent_Failed(), ecorePackage.getEBoolean(), "failed", null, 0, 1, ConstantEvent.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
581 | |||
582 | // Create resource | ||
583 | createResource(eNS_URI); | ||
584 | } | ||
585 | |||
586 | } //FtPackageImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/GateImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/GateImpl.java deleted file mode 100644 index 9e753a09..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/GateImpl.java +++ /dev/null | |||
@@ -1,133 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.Gate; | ||
7 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.RandomEvent; | ||
8 | |||
9 | import java.util.Collection; | ||
10 | |||
11 | import org.eclipse.emf.common.util.EList; | ||
12 | |||
13 | import org.eclipse.emf.ecore.EClass; | ||
14 | |||
15 | import org.eclipse.emf.ecore.util.EObjectResolvingEList; | ||
16 | |||
17 | /** | ||
18 | * <!-- begin-user-doc --> | ||
19 | * An implementation of the model object '<em><b>Gate</b></em>'. | ||
20 | * <!-- end-user-doc --> | ||
21 | * <p> | ||
22 | * The following features are implemented: | ||
23 | * </p> | ||
24 | * <ul> | ||
25 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.GateImpl#getInputEvents <em>Input Events</em>}</li> | ||
26 | * </ul> | ||
27 | * | ||
28 | * @generated | ||
29 | */ | ||
30 | public abstract class GateImpl extends RandomEventImpl implements Gate { | ||
31 | /** | ||
32 | * The cached value of the '{@link #getInputEvents() <em>Input Events</em>}' reference list. | ||
33 | * <!-- begin-user-doc --> | ||
34 | * <!-- end-user-doc --> | ||
35 | * @see #getInputEvents() | ||
36 | * @generated | ||
37 | * @ordered | ||
38 | */ | ||
39 | protected EList<RandomEvent> inputEvents; | ||
40 | |||
41 | /** | ||
42 | * <!-- begin-user-doc --> | ||
43 | * <!-- end-user-doc --> | ||
44 | * @generated | ||
45 | */ | ||
46 | protected GateImpl() { | ||
47 | super(); | ||
48 | } | ||
49 | |||
50 | /** | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @generated | ||
54 | */ | ||
55 | @Override | ||
56 | protected EClass eStaticClass() { | ||
57 | return FtPackage.Literals.GATE; | ||
58 | } | ||
59 | |||
60 | /** | ||
61 | * <!-- begin-user-doc --> | ||
62 | * <!-- end-user-doc --> | ||
63 | * @generated | ||
64 | */ | ||
65 | @Override | ||
66 | public EList<RandomEvent> getInputEvents() { | ||
67 | if (inputEvents == null) { | ||
68 | inputEvents = new EObjectResolvingEList<RandomEvent>(RandomEvent.class, this, FtPackage.GATE__INPUT_EVENTS); | ||
69 | } | ||
70 | return inputEvents; | ||
71 | } | ||
72 | |||
73 | /** | ||
74 | * <!-- begin-user-doc --> | ||
75 | * <!-- end-user-doc --> | ||
76 | * @generated | ||
77 | */ | ||
78 | @Override | ||
79 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
80 | switch (featureID) { | ||
81 | case FtPackage.GATE__INPUT_EVENTS: | ||
82 | return getInputEvents(); | ||
83 | } | ||
84 | return super.eGet(featureID, resolve, coreType); | ||
85 | } | ||
86 | |||
87 | /** | ||
88 | * <!-- begin-user-doc --> | ||
89 | * <!-- end-user-doc --> | ||
90 | * @generated | ||
91 | */ | ||
92 | @SuppressWarnings("unchecked") | ||
93 | @Override | ||
94 | public void eSet(int featureID, Object newValue) { | ||
95 | switch (featureID) { | ||
96 | case FtPackage.GATE__INPUT_EVENTS: | ||
97 | getInputEvents().clear(); | ||
98 | getInputEvents().addAll((Collection<? extends RandomEvent>)newValue); | ||
99 | return; | ||
100 | } | ||
101 | super.eSet(featureID, newValue); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eUnset(int featureID) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.GATE__INPUT_EVENTS: | ||
113 | getInputEvents().clear(); | ||
114 | return; | ||
115 | } | ||
116 | super.eUnset(featureID); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public boolean eIsSet(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.GATE__INPUT_EVENTS: | ||
128 | return inputEvents != null && !inputEvents.isEmpty(); | ||
129 | } | ||
130 | return super.eIsSet(featureID); | ||
131 | } | ||
132 | |||
133 | } //GateImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/KOfMGateImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/KOfMGateImpl.java deleted file mode 100644 index 47ca936b..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/KOfMGateImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.KOfMGate; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>KOf MGate</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.KOfMGateImpl#getK <em>K</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public class KOfMGateImpl extends GateImpl implements KOfMGate { | ||
28 | /** | ||
29 | * The default value of the '{@link #getK() <em>K</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #getK() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final int K_EDEFAULT = 0; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #getK() <em>K</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #getK() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected int k = K_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected KOfMGateImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.KOF_MGATE; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public int getK() { | ||
74 | return k; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setK(int newK) { | ||
84 | int oldK = k; | ||
85 | k = newK; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.KOF_MGATE__K, oldK, k)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.KOF_MGATE__K: | ||
99 | return getK(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.KOF_MGATE__K: | ||
113 | setK((Integer)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.KOF_MGATE__K: | ||
128 | setK(K_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.KOF_MGATE__K: | ||
143 | return k != K_EDEFAULT; | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (k: "); | ||
159 | result.append(k); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //KOfMGateImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/OrGateImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/OrGateImpl.java deleted file mode 100644 index 88bd2bae..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/OrGateImpl.java +++ /dev/null | |||
@@ -1,37 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.OrGate; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Or Gate</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public class OrGateImpl extends GateImpl implements OrGate { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected OrGateImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return FtPackage.Literals.OR_GATE; | ||
35 | } | ||
36 | |||
37 | } //OrGateImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/RandomEventImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/RandomEventImpl.java deleted file mode 100644 index 4f9eda56..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/RandomEventImpl.java +++ /dev/null | |||
@@ -1,164 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.RandomEvent; | ||
7 | |||
8 | import org.eclipse.emf.common.notify.Notification; | ||
9 | |||
10 | import org.eclipse.emf.ecore.EClass; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | |||
14 | /** | ||
15 | * <!-- begin-user-doc --> | ||
16 | * An implementation of the model object '<em><b>Random Event</b></em>'. | ||
17 | * <!-- end-user-doc --> | ||
18 | * <p> | ||
19 | * The following features are implemented: | ||
20 | * </p> | ||
21 | * <ul> | ||
22 | * <li>{@link hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl.RandomEventImpl#getName <em>Name</em>}</li> | ||
23 | * </ul> | ||
24 | * | ||
25 | * @generated | ||
26 | */ | ||
27 | public abstract class RandomEventImpl extends EventImpl implements RandomEvent { | ||
28 | /** | ||
29 | * The default value of the '{@link #getName() <em>Name</em>}' attribute. | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @see #getName() | ||
33 | * @generated | ||
34 | * @ordered | ||
35 | */ | ||
36 | protected static final String NAME_EDEFAULT = null; | ||
37 | |||
38 | /** | ||
39 | * The cached value of the '{@link #getName() <em>Name</em>}' attribute. | ||
40 | * <!-- begin-user-doc --> | ||
41 | * <!-- end-user-doc --> | ||
42 | * @see #getName() | ||
43 | * @generated | ||
44 | * @ordered | ||
45 | */ | ||
46 | protected String name = NAME_EDEFAULT; | ||
47 | |||
48 | /** | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @generated | ||
52 | */ | ||
53 | protected RandomEventImpl() { | ||
54 | super(); | ||
55 | } | ||
56 | |||
57 | /** | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @generated | ||
61 | */ | ||
62 | @Override | ||
63 | protected EClass eStaticClass() { | ||
64 | return FtPackage.Literals.RANDOM_EVENT; | ||
65 | } | ||
66 | |||
67 | /** | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @generated | ||
71 | */ | ||
72 | @Override | ||
73 | public String getName() { | ||
74 | return name; | ||
75 | } | ||
76 | |||
77 | /** | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @generated | ||
81 | */ | ||
82 | @Override | ||
83 | public void setName(String newName) { | ||
84 | String oldName = name; | ||
85 | name = newName; | ||
86 | if (eNotificationRequired()) | ||
87 | eNotify(new ENotificationImpl(this, Notification.SET, FtPackage.RANDOM_EVENT__NAME, oldName, name)); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case FtPackage.RANDOM_EVENT__NAME: | ||
99 | return getName(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @Override | ||
110 | public void eSet(int featureID, Object newValue) { | ||
111 | switch (featureID) { | ||
112 | case FtPackage.RANDOM_EVENT__NAME: | ||
113 | setName((String)newValue); | ||
114 | return; | ||
115 | } | ||
116 | super.eSet(featureID, newValue); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public void eUnset(int featureID) { | ||
126 | switch (featureID) { | ||
127 | case FtPackage.RANDOM_EVENT__NAME: | ||
128 | setName(NAME_EDEFAULT); | ||
129 | return; | ||
130 | } | ||
131 | super.eUnset(featureID); | ||
132 | } | ||
133 | |||
134 | /** | ||
135 | * <!-- begin-user-doc --> | ||
136 | * <!-- end-user-doc --> | ||
137 | * @generated | ||
138 | */ | ||
139 | @Override | ||
140 | public boolean eIsSet(int featureID) { | ||
141 | switch (featureID) { | ||
142 | case FtPackage.RANDOM_EVENT__NAME: | ||
143 | return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); | ||
144 | } | ||
145 | return super.eIsSet(featureID); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public String toString() { | ||
155 | if (eIsProxy()) return super.toString(); | ||
156 | |||
157 | StringBuilder result = new StringBuilder(super.toString()); | ||
158 | result.append(" (name: "); | ||
159 | result.append(name); | ||
160 | result.append(')'); | ||
161 | return result.toString(); | ||
162 | } | ||
163 | |||
164 | } //RandomEventImpl | ||
diff --git a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ReliabilityModelImpl.java b/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ReliabilityModelImpl.java deleted file mode 100644 index e3d0eec1..00000000 --- a/Stochastic/hu.bme.mit.inf.dslreasoner.faulttree.model/ecore-gen/hu/bme/mit/inf/dslreasoner/faulttree/model/ft/impl/ReliabilityModelImpl.java +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.faulttree.model.ft.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.FtPackage; | ||
6 | import hu.bme.mit.inf.dslreasoner.faulttree.model.ft.ReliabilityModel; | ||
7 | |||
8 | import org.eclipse.emf.ecore.EClass; | ||
9 | |||
10 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
11 | |||
12 | /** | ||
13 | * <!-- begin-user-doc --> | ||
14 | * An implementation of the model object '<em><b>Reliability Model</b></em>'. | ||
15 | * <!-- end-user-doc --> | ||
16 | * | ||
17 | * @generated | ||
18 | */ | ||
19 | public abstract class ReliabilityModelImpl extends MinimalEObjectImpl.Container implements ReliabilityModel { | ||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * <!-- end-user-doc --> | ||
23 | * @generated | ||
24 | */ | ||
25 | protected ReliabilityModelImpl() { | ||
26 | super(); | ||
27 | } | ||
28 | |||
29 | /** | ||
30 | * <!-- begin-user-doc --> | ||
31 | * <!-- end-user-doc --> | ||
32 | * @generated | ||
33 | */ | ||
34 | @Override | ||
35 | protected EClass eStaticClass() { | ||
36 | return FtPackage.Literals.RELIABILITY_MODEL; | ||
37 | } | ||
38 | |||
39 | } //ReliabilityModelImpl | ||