1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34 package ca.uhn.hl7v2.model.v27.segment;
35
36
37 import ca.uhn.hl7v2.model.v27.datatype.*;
38 import ca.uhn.hl7v2.HL7Exception;
39 import ca.uhn.hl7v2.parser.ModelClassFactory;
40 import ca.uhn.hl7v2.parser.DefaultModelClassFactory;
41 import ca.uhn.hl7v2.model.AbstractMessage;
42 import ca.uhn.hl7v2.model.Group;
43 import ca.uhn.hl7v2.model.Type;
44 import ca.uhn.hl7v2.model.AbstractSegment;
45 import ca.uhn.hl7v2.model.Varies;
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70 @SuppressWarnings("unused")
71 public class REL extends AbstractSegment {
72
73
74
75
76 public REL(Group parent, ModelClassFactory factory) {
77 super(parent, factory);
78 init(factory);
79 }
80
81 private void init(ModelClassFactory factory) {
82 try {
83 this.add(SI.class, false, 1, 4, new Object[]{ getMessage() }, "Set ID -REL");
84 this.add(CWE.class, true, 1, 0, new Object[]{ getMessage() }, "Relationship Type");
85 this.add(EI.class, true, 1, 0, new Object[]{ getMessage() }, "This Relationship Instance Identifier");
86 this.add(EI.class, true, 1, 0, new Object[]{ getMessage() }, "Source Information Instance Identifier");
87 this.add(EI.class, true, 1, 0, new Object[]{ getMessage() }, "Target Information Instance Identifier");
88 this.add(EI.class, false, 1, 0, new Object[]{ getMessage() }, "Asserting Entity Instance ID");
89 this.add(XCN.class, false, 1, 0, new Object[]{ getMessage() }, "Asserting Person");
90 this.add(XON.class, false, 1, 0, new Object[]{ getMessage() }, "Asserting Organization");
91 this.add(XAD.class, false, 1, 0, new Object[]{ getMessage() }, "Assertor Address");
92 this.add(XTN.class, false, 1, 0, new Object[]{ getMessage() }, "Assertor Contact");
93 this.add(DR.class, false, 1, 0, new Object[]{ getMessage() }, "Assertion Date Range");
94 this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(136) }, "Negation Indicator");
95 this.add(CWE.class, false, 1, 0, new Object[]{ getMessage() }, "Certainty of Relationship");
96 this.add(NM.class, false, 1, 0, new Object[]{ getMessage() }, "Priority No");
97 this.add(NM.class, false, 1, 0, new Object[]{ getMessage() }, "Priority Sequence No (rel preference for consideration)");
98 this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(136) }, "Separability Indicator");
99 } catch(HL7Exception e) {
100 log.error("Unexpected error creating REL - this is probably a bug in the source code generator.", e);
101 }
102 }
103
104
105
106
107
108
109
110 public SI getSetIDREL() {
111 SI retVal = this.getTypedField(1, 0);
112 return retVal;
113 }
114
115
116
117
118
119 public SI getRel1_SetIDREL() {
120 SI retVal = this.getTypedField(1, 0);
121 return retVal;
122 }
123
124
125
126
127
128
129
130 public CWE getRelationshipType() {
131 CWE retVal = this.getTypedField(2, 0);
132 return retVal;
133 }
134
135
136
137
138
139 public CWE getRel2_RelationshipType() {
140 CWE retVal = this.getTypedField(2, 0);
141 return retVal;
142 }
143
144
145
146
147
148
149
150 public EI getThisRelationshipInstanceIdentifier() {
151 EI retVal = this.getTypedField(3, 0);
152 return retVal;
153 }
154
155
156
157
158
159 public EI getRel3_ThisRelationshipInstanceIdentifier() {
160 EI retVal = this.getTypedField(3, 0);
161 return retVal;
162 }
163
164
165
166
167
168
169
170 public EI getSourceInformationInstanceIdentifier() {
171 EI retVal = this.getTypedField(4, 0);
172 return retVal;
173 }
174
175
176
177
178
179 public EI getRel4_SourceInformationInstanceIdentifier() {
180 EI retVal = this.getTypedField(4, 0);
181 return retVal;
182 }
183
184
185
186
187
188
189
190 public EI getTargetInformationInstanceIdentifier() {
191 EI retVal = this.getTypedField(5, 0);
192 return retVal;
193 }
194
195
196
197
198
199 public EI getRel5_TargetInformationInstanceIdentifier() {
200 EI retVal = this.getTypedField(5, 0);
201 return retVal;
202 }
203
204
205
206
207
208
209
210 public EI getAssertingEntityInstanceID() {
211 EI retVal = this.getTypedField(6, 0);
212 return retVal;
213 }
214
215
216
217
218
219 public EI getRel6_AssertingEntityInstanceID() {
220 EI retVal = this.getTypedField(6, 0);
221 return retVal;
222 }
223
224
225
226
227
228
229
230 public XCN getAssertingPerson() {
231 XCN retVal = this.getTypedField(7, 0);
232 return retVal;
233 }
234
235
236
237
238
239 public XCN getRel7_AssertingPerson() {
240 XCN retVal = this.getTypedField(7, 0);
241 return retVal;
242 }
243
244
245
246
247
248
249
250 public XON getAssertingOrganization() {
251 XON retVal = this.getTypedField(8, 0);
252 return retVal;
253 }
254
255
256
257
258
259 public XON getRel8_AssertingOrganization() {
260 XON retVal = this.getTypedField(8, 0);
261 return retVal;
262 }
263
264
265
266
267
268
269
270 public XAD getAssertorAddress() {
271 XAD retVal = this.getTypedField(9, 0);
272 return retVal;
273 }
274
275
276
277
278
279 public XAD getRel9_AssertorAddress() {
280 XAD retVal = this.getTypedField(9, 0);
281 return retVal;
282 }
283
284
285
286
287
288
289
290 public XTN getAssertorContact() {
291 XTN retVal = this.getTypedField(10, 0);
292 return retVal;
293 }
294
295
296
297
298
299 public XTN getRel10_AssertorContact() {
300 XTN retVal = this.getTypedField(10, 0);
301 return retVal;
302 }
303
304
305
306
307
308
309
310 public DR getAssertionDateRange() {
311 DR retVal = this.getTypedField(11, 0);
312 return retVal;
313 }
314
315
316
317
318
319 public DR getRel11_AssertionDateRange() {
320 DR retVal = this.getTypedField(11, 0);
321 return retVal;
322 }
323
324
325
326
327
328
329
330 public ID getNegationIndicator() {
331 ID retVal = this.getTypedField(12, 0);
332 return retVal;
333 }
334
335
336
337
338
339 public ID getRel12_NegationIndicator() {
340 ID retVal = this.getTypedField(12, 0);
341 return retVal;
342 }
343
344
345
346
347
348
349
350 public CWE getCertaintyOfRelationship() {
351 CWE retVal = this.getTypedField(13, 0);
352 return retVal;
353 }
354
355
356
357
358
359 public CWE getRel13_CertaintyOfRelationship() {
360 CWE retVal = this.getTypedField(13, 0);
361 return retVal;
362 }
363
364
365
366
367
368
369
370 public NM getPriorityNo() {
371 NM retVal = this.getTypedField(14, 0);
372 return retVal;
373 }
374
375
376
377
378
379 public NM getRel14_PriorityNo() {
380 NM retVal = this.getTypedField(14, 0);
381 return retVal;
382 }
383
384
385
386
387
388
389
390 public NM getPrioritySequenceNoRelpreferenceforconsideration() {
391 NM retVal = this.getTypedField(15, 0);
392 return retVal;
393 }
394
395
396
397
398
399 public NM getRel15_PrioritySequenceNoRelpreferenceforconsideration() {
400 NM retVal = this.getTypedField(15, 0);
401 return retVal;
402 }
403
404
405
406
407
408
409
410 public ID getSeparabilityIndicator() {
411 ID retVal = this.getTypedField(16, 0);
412 return retVal;
413 }
414
415
416
417
418
419 public ID getRel16_SeparabilityIndicator() {
420 ID retVal = this.getTypedField(16, 0);
421 return retVal;
422 }
423
424
425
426
427
428
429 protected Type createNewTypeWithoutReflection(int field) {
430 switch (field) {
431 case 0: return new SI(getMessage());
432 case 1: return new CWE(getMessage());
433 case 2: return new EI(getMessage());
434 case 3: return new EI(getMessage());
435 case 4: return new EI(getMessage());
436 case 5: return new EI(getMessage());
437 case 6: return new XCN(getMessage());
438 case 7: return new XON(getMessage());
439 case 8: return new XAD(getMessage());
440 case 9: return new XTN(getMessage());
441 case 10: return new DR(getMessage());
442 case 11: return new ID(getMessage(), new Integer( 136 ));
443 case 12: return new CWE(getMessage());
444 case 13: return new NM(getMessage());
445 case 14: return new NM(getMessage());
446 case 15: return new ID(getMessage(), new Integer( 136 ));
447 default: return null;
448 }
449 }
450
451
452 }
453