diff options
Diffstat (limited to 'Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/SatelliteFactoryImpl.java')
-rw-r--r-- | Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/SatelliteFactoryImpl.java | 255 |
1 files changed, 255 insertions, 0 deletions
diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/SatelliteFactoryImpl.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/SatelliteFactoryImpl.java new file mode 100644 index 00000000..0cb07cfa --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/SatelliteFactoryImpl.java | |||
@@ -0,0 +1,255 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.domains.satellite.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.domains.satellite.*; | ||
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 SatelliteFactoryImpl extends EFactoryImpl implements SatelliteFactory { | ||
23 | /** | ||
24 | * Creates the default factory implementation. | ||
25 | * <!-- begin-user-doc --> | ||
26 | * <!-- end-user-doc --> | ||
27 | * @generated | ||
28 | */ | ||
29 | public static SatelliteFactory init() { | ||
30 | try { | ||
31 | SatelliteFactory theSatelliteFactory = (SatelliteFactory) EPackage.Registry.INSTANCE | ||
32 | .getEFactory(SatellitePackage.eNS_URI); | ||
33 | if (theSatelliteFactory != null) { | ||
34 | return theSatelliteFactory; | ||
35 | } | ||
36 | } catch (Exception exception) { | ||
37 | EcorePlugin.INSTANCE.log(exception); | ||
38 | } | ||
39 | return new SatelliteFactoryImpl(); | ||
40 | } | ||
41 | |||
42 | /** | ||
43 | * Creates an instance of the factory. | ||
44 | * <!-- begin-user-doc --> | ||
45 | * <!-- end-user-doc --> | ||
46 | * @generated | ||
47 | */ | ||
48 | public SatelliteFactoryImpl() { | ||
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 SatellitePackage.INTERFEROMETRY_MISSION: | ||
61 | return createInterferometryMission(); | ||
62 | case SatellitePackage.GROUND_STATION_NETWORK: | ||
63 | return createGroundStationNetwork(); | ||
64 | case SatellitePackage.COMM_SUBSYSTEM: | ||
65 | return createCommSubsystem(); | ||
66 | case SatellitePackage.DIRECTED_COMMUNICATION_LINK: | ||
67 | return createDirectedCommunicationLink(); | ||
68 | case SatellitePackage.INTERFEROMETRY_PAYLOAD: | ||
69 | return createInterferometryPayload(); | ||
70 | default: | ||
71 | throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); | ||
72 | } | ||
73 | } | ||
74 | |||
75 | /** | ||
76 | * <!-- begin-user-doc --> | ||
77 | * <!-- end-user-doc --> | ||
78 | * @generated | ||
79 | */ | ||
80 | @Override | ||
81 | public Object createFromString(EDataType eDataType, String initialValue) { | ||
82 | switch (eDataType.getClassifierID()) { | ||
83 | case SatellitePackage.TRANSCEIVER_BAND: | ||
84 | return createTransceiverBandFromString(eDataType, initialValue); | ||
85 | case SatellitePackage.ANTENNA_GAIN: | ||
86 | return createAntennaGainFromString(eDataType, initialValue); | ||
87 | case SatellitePackage.SPACECRAFT_KIND: | ||
88 | return createSpacecraftKindFromString(eDataType, initialValue); | ||
89 | default: | ||
90 | throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); | ||
91 | } | ||
92 | } | ||
93 | |||
94 | /** | ||
95 | * <!-- begin-user-doc --> | ||
96 | * <!-- end-user-doc --> | ||
97 | * @generated | ||
98 | */ | ||
99 | @Override | ||
100 | public String convertToString(EDataType eDataType, Object instanceValue) { | ||
101 | switch (eDataType.getClassifierID()) { | ||
102 | case SatellitePackage.TRANSCEIVER_BAND: | ||
103 | return convertTransceiverBandToString(eDataType, instanceValue); | ||
104 | case SatellitePackage.ANTENNA_GAIN: | ||
105 | return convertAntennaGainToString(eDataType, instanceValue); | ||
106 | case SatellitePackage.SPACECRAFT_KIND: | ||
107 | return convertSpacecraftKindToString(eDataType, instanceValue); | ||
108 | default: | ||
109 | throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); | ||
110 | } | ||
111 | } | ||
112 | |||
113 | /** | ||
114 | * <!-- begin-user-doc --> | ||
115 | * <!-- end-user-doc --> | ||
116 | * @generated | ||
117 | */ | ||
118 | @Override | ||
119 | public InterferometryMission createInterferometryMission() { | ||
120 | InterferometryMissionImpl interferometryMission = new InterferometryMissionImpl(); | ||
121 | return interferometryMission; | ||
122 | } | ||
123 | |||
124 | /** | ||
125 | * <!-- begin-user-doc --> | ||
126 | * <!-- end-user-doc --> | ||
127 | * @generated | ||
128 | */ | ||
129 | @Override | ||
130 | public GroundStationNetwork createGroundStationNetwork() { | ||
131 | GroundStationNetworkImpl groundStationNetwork = new GroundStationNetworkImpl(); | ||
132 | return groundStationNetwork; | ||
133 | } | ||
134 | |||
135 | /** | ||
136 | * <!-- begin-user-doc --> | ||
137 | * <!-- end-user-doc --> | ||
138 | * @generated | ||
139 | */ | ||
140 | @Override | ||
141 | public CommSubsystem createCommSubsystem() { | ||
142 | CommSubsystemImpl commSubsystem = new CommSubsystemImpl(); | ||
143 | return commSubsystem; | ||
144 | } | ||
145 | |||
146 | /** | ||
147 | * <!-- begin-user-doc --> | ||
148 | * <!-- end-user-doc --> | ||
149 | * @generated | ||
150 | */ | ||
151 | @Override | ||
152 | public DirectedCommunicationLink createDirectedCommunicationLink() { | ||
153 | DirectedCommunicationLinkImpl directedCommunicationLink = new DirectedCommunicationLinkImpl(); | ||
154 | return directedCommunicationLink; | ||
155 | } | ||
156 | |||
157 | /** | ||
158 | * <!-- begin-user-doc --> | ||
159 | * <!-- end-user-doc --> | ||
160 | * @generated | ||
161 | */ | ||
162 | @Override | ||
163 | public InterferometryPayload createInterferometryPayload() { | ||
164 | InterferometryPayloadImpl interferometryPayload = new InterferometryPayloadImpl(); | ||
165 | return interferometryPayload; | ||
166 | } | ||
167 | |||
168 | /** | ||
169 | * <!-- begin-user-doc --> | ||
170 | * <!-- end-user-doc --> | ||
171 | * @generated | ||
172 | */ | ||
173 | public TransceiverBand createTransceiverBandFromString(EDataType eDataType, String initialValue) { | ||
174 | TransceiverBand result = TransceiverBand.get(initialValue); | ||
175 | if (result == null) | ||
176 | throw new IllegalArgumentException( | ||
177 | "The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); | ||
178 | return result; | ||
179 | } | ||
180 | |||
181 | /** | ||
182 | * <!-- begin-user-doc --> | ||
183 | * <!-- end-user-doc --> | ||
184 | * @generated | ||
185 | */ | ||
186 | public String convertTransceiverBandToString(EDataType eDataType, Object instanceValue) { | ||
187 | return instanceValue == null ? null : instanceValue.toString(); | ||
188 | } | ||
189 | |||
190 | /** | ||
191 | * <!-- begin-user-doc --> | ||
192 | * <!-- end-user-doc --> | ||
193 | * @generated | ||
194 | */ | ||
195 | public AntennaGain createAntennaGainFromString(EDataType eDataType, String initialValue) { | ||
196 | AntennaGain result = AntennaGain.get(initialValue); | ||
197 | if (result == null) | ||
198 | throw new IllegalArgumentException( | ||
199 | "The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); | ||
200 | return result; | ||
201 | } | ||
202 | |||
203 | /** | ||
204 | * <!-- begin-user-doc --> | ||
205 | * <!-- end-user-doc --> | ||
206 | * @generated | ||
207 | */ | ||
208 | public String convertAntennaGainToString(EDataType eDataType, Object instanceValue) { | ||
209 | return instanceValue == null ? null : instanceValue.toString(); | ||
210 | } | ||
211 | |||
212 | /** | ||
213 | * <!-- begin-user-doc --> | ||
214 | * <!-- end-user-doc --> | ||
215 | * @generated | ||
216 | */ | ||
217 | public SpacecraftKind createSpacecraftKindFromString(EDataType eDataType, String initialValue) { | ||
218 | SpacecraftKind result = SpacecraftKind.get(initialValue); | ||
219 | if (result == null) | ||
220 | throw new IllegalArgumentException( | ||
221 | "The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); | ||
222 | return result; | ||
223 | } | ||
224 | |||
225 | /** | ||
226 | * <!-- begin-user-doc --> | ||
227 | * <!-- end-user-doc --> | ||
228 | * @generated | ||
229 | */ | ||
230 | public String convertSpacecraftKindToString(EDataType eDataType, Object instanceValue) { | ||
231 | return instanceValue == null ? null : instanceValue.toString(); | ||
232 | } | ||
233 | |||
234 | /** | ||
235 | * <!-- begin-user-doc --> | ||
236 | * <!-- end-user-doc --> | ||
237 | * @generated | ||
238 | */ | ||
239 | @Override | ||
240 | public SatellitePackage getSatellitePackage() { | ||
241 | return (SatellitePackage) getEPackage(); | ||
242 | } | ||
243 | |||
244 | /** | ||
245 | * <!-- begin-user-doc --> | ||
246 | * <!-- end-user-doc --> | ||
247 | * @deprecated | ||
248 | * @generated | ||
249 | */ | ||
250 | @Deprecated | ||
251 | public static SatellitePackage getPackage() { | ||
252 | return SatellitePackage.eINSTANCE; | ||
253 | } | ||
254 | |||
255 | } //SatelliteFactoryImpl | ||