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.v281.segment;
35
36
37 import ca.uhn.hl7v2.model.v281.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 @SuppressWarnings("unused")
69 public class ROL extends AbstractSegment {
70
71
72
73
74 public ROL(Group parent, ModelClassFactory factory) {
75 super(parent, factory);
76 init(factory);
77 }
78
79 private void init(ModelClassFactory factory) {
80 try {
81 this.add(EI.class, false, 1, 0, new Object[]{ getMessage() }, "Role Instance ID");
82 this.add(ID.class, true, 1, 0, new Object[]{ getMessage(), new Integer(206) }, "Action Code");
83 this.add(CWE.class, true, 1, 0, new Object[]{ getMessage() }, "Role-ROL");
84 this.add(XCN.class, true, 0, 0, new Object[]{ getMessage() }, "Role Person");
85 this.add(DTM.class, false, 1, 0, new Object[]{ getMessage() }, "Role Begin Date/Time");
86 this.add(DTM.class, false, 1, 0, new Object[]{ getMessage() }, "Role End Date/Time");
87 this.add(CWE.class, false, 1, 0, new Object[]{ getMessage() }, "Role Duration");
88 this.add(CWE.class, false, 1, 0, new Object[]{ getMessage() }, "Role Action Reason");
89 this.add(CWE.class, false, 0, 0, new Object[]{ getMessage() }, "Provider Type");
90 this.add(CWE.class, false, 1, 0, new Object[]{ getMessage() }, "Organization Unit Type");
91 this.add(XAD.class, false, 0, 0, new Object[]{ getMessage() }, "Office/Home Address/Birthplace");
92 this.add(XTN.class, false, 0, 0, new Object[]{ getMessage() }, "Phone");
93 this.add(PL.class, false, 1, 0, new Object[]{ getMessage() }, "Person's Location");
94 this.add(XON.class, false, 1, 0, new Object[]{ getMessage() }, "Organization");
95 } catch(HL7Exception e) {
96 log.error("Unexpected error creating ROL - this is probably a bug in the source code generator.", e);
97 }
98 }
99
100
101
102
103
104
105
106 public EI getRoleInstanceID() {
107 EI retVal = this.getTypedField(1, 0);
108 return retVal;
109 }
110
111
112
113
114
115 public EI getRol1_RoleInstanceID() {
116 EI retVal = this.getTypedField(1, 0);
117 return retVal;
118 }
119
120
121
122
123
124
125
126 public ID getActionCode() {
127 ID retVal = this.getTypedField(2, 0);
128 return retVal;
129 }
130
131
132
133
134
135 public ID getRol2_ActionCode() {
136 ID retVal = this.getTypedField(2, 0);
137 return retVal;
138 }
139
140
141
142
143
144
145
146 public CWE getRoleROL() {
147 CWE retVal = this.getTypedField(3, 0);
148 return retVal;
149 }
150
151
152
153
154
155 public CWE getRol3_RoleROL() {
156 CWE retVal = this.getTypedField(3, 0);
157 return retVal;
158 }
159
160
161
162
163
164 public XCN[] getRolePerson() {
165 XCN[] retVal = this.getTypedField(4, new XCN[0]);
166 return retVal;
167 }
168
169
170
171
172
173 public XCN[] getRol4_RolePerson() {
174 XCN[] retVal = this.getTypedField(4, new XCN[0]);
175 return retVal;
176 }
177
178
179
180
181
182
183
184 public int getRolePersonReps() {
185 return this.getReps(4);
186 }
187
188
189
190
191
192
193
194
195 public XCN getRolePerson(int rep) {
196 XCN retVal = this.getTypedField(4, rep);
197 return retVal;
198 }
199
200
201
202
203
204
205
206 public XCN getRol4_RolePerson(int rep) {
207 XCN retVal = this.getTypedField(4, rep);
208 return retVal;
209 }
210
211
212
213
214
215
216 public int getRol4_RolePersonReps() {
217 return this.getReps(4);
218 }
219
220
221
222
223
224
225
226
227
228 public XCN insertRolePerson(int rep) throws HL7Exception {
229 return (XCN) super.insertRepetition(4, rep);
230 }
231
232
233
234
235
236
237
238
239
240 public XCN insertRol4_RolePerson(int rep) throws HL7Exception {
241 return (XCN) super.insertRepetition(4, rep);
242 }
243
244
245
246
247
248
249
250
251
252 public XCN removeRolePerson(int rep) throws HL7Exception {
253 return (XCN) super.removeRepetition(4, rep);
254 }
255
256
257
258
259
260
261
262
263
264 public XCN removeRol4_RolePerson(int rep) throws HL7Exception {
265 return (XCN) super.removeRepetition(4, rep);
266 }
267
268
269
270
271
272
273
274
275 public DTM getRoleBeginDateTime() {
276 DTM retVal = this.getTypedField(5, 0);
277 return retVal;
278 }
279
280
281
282
283
284 public DTM getRol5_RoleBeginDateTime() {
285 DTM retVal = this.getTypedField(5, 0);
286 return retVal;
287 }
288
289
290
291
292
293
294
295 public DTM getRoleEndDateTime() {
296 DTM retVal = this.getTypedField(6, 0);
297 return retVal;
298 }
299
300
301
302
303
304 public DTM getRol6_RoleEndDateTime() {
305 DTM retVal = this.getTypedField(6, 0);
306 return retVal;
307 }
308
309
310
311
312
313
314
315 public CWE getRoleDuration() {
316 CWE retVal = this.getTypedField(7, 0);
317 return retVal;
318 }
319
320
321
322
323
324 public CWE getRol7_RoleDuration() {
325 CWE retVal = this.getTypedField(7, 0);
326 return retVal;
327 }
328
329
330
331
332
333
334
335 public CWE getRoleActionReason() {
336 CWE retVal = this.getTypedField(8, 0);
337 return retVal;
338 }
339
340
341
342
343
344 public CWE getRol8_RoleActionReason() {
345 CWE retVal = this.getTypedField(8, 0);
346 return retVal;
347 }
348
349
350
351
352
353 public CWE[] getProviderType() {
354 CWE[] retVal = this.getTypedField(9, new CWE[0]);
355 return retVal;
356 }
357
358
359
360
361
362 public CWE[] getRol9_ProviderType() {
363 CWE[] retVal = this.getTypedField(9, new CWE[0]);
364 return retVal;
365 }
366
367
368
369
370
371
372
373 public int getProviderTypeReps() {
374 return this.getReps(9);
375 }
376
377
378
379
380
381
382
383
384 public CWE getProviderType(int rep) {
385 CWE retVal = this.getTypedField(9, rep);
386 return retVal;
387 }
388
389
390
391
392
393
394
395 public CWE getRol9_ProviderType(int rep) {
396 CWE retVal = this.getTypedField(9, rep);
397 return retVal;
398 }
399
400
401
402
403
404
405 public int getRol9_ProviderTypeReps() {
406 return this.getReps(9);
407 }
408
409
410
411
412
413
414
415
416
417 public CWE insertProviderType(int rep) throws HL7Exception {
418 return (CWE) super.insertRepetition(9, rep);
419 }
420
421
422
423
424
425
426
427
428
429 public CWE insertRol9_ProviderType(int rep) throws HL7Exception {
430 return (CWE) super.insertRepetition(9, rep);
431 }
432
433
434
435
436
437
438
439
440
441 public CWE removeProviderType(int rep) throws HL7Exception {
442 return (CWE) super.removeRepetition(9, rep);
443 }
444
445
446
447
448
449
450
451
452
453 public CWE removeRol9_ProviderType(int rep) throws HL7Exception {
454 return (CWE) super.removeRepetition(9, rep);
455 }
456
457
458
459
460
461
462
463
464 public CWE getOrganizationUnitType() {
465 CWE retVal = this.getTypedField(10, 0);
466 return retVal;
467 }
468
469
470
471
472
473 public CWE getRol10_OrganizationUnitType() {
474 CWE retVal = this.getTypedField(10, 0);
475 return retVal;
476 }
477
478
479
480
481
482 public XAD[] getOfficeHomeAddressBirthplace() {
483 XAD[] retVal = this.getTypedField(11, new XAD[0]);
484 return retVal;
485 }
486
487
488
489
490
491 public XAD[] getRol11_OfficeHomeAddressBirthplace() {
492 XAD[] retVal = this.getTypedField(11, new XAD[0]);
493 return retVal;
494 }
495
496
497
498
499
500
501
502 public int getOfficeHomeAddressBirthplaceReps() {
503 return this.getReps(11);
504 }
505
506
507
508
509
510
511
512
513 public XAD getOfficeHomeAddressBirthplace(int rep) {
514 XAD retVal = this.getTypedField(11, rep);
515 return retVal;
516 }
517
518
519
520
521
522
523
524 public XAD getRol11_OfficeHomeAddressBirthplace(int rep) {
525 XAD retVal = this.getTypedField(11, rep);
526 return retVal;
527 }
528
529
530
531
532
533
534 public int getRol11_OfficeHomeAddressBirthplaceReps() {
535 return this.getReps(11);
536 }
537
538
539
540
541
542
543
544
545
546 public XAD insertOfficeHomeAddressBirthplace(int rep) throws HL7Exception {
547 return (XAD) super.insertRepetition(11, rep);
548 }
549
550
551
552
553
554
555
556
557
558 public XAD insertRol11_OfficeHomeAddressBirthplace(int rep) throws HL7Exception {
559 return (XAD) super.insertRepetition(11, rep);
560 }
561
562
563
564
565
566
567
568
569
570 public XAD removeOfficeHomeAddressBirthplace(int rep) throws HL7Exception {
571 return (XAD) super.removeRepetition(11, rep);
572 }
573
574
575
576
577
578
579
580
581
582 public XAD removeRol11_OfficeHomeAddressBirthplace(int rep) throws HL7Exception {
583 return (XAD) super.removeRepetition(11, rep);
584 }
585
586
587
588
589
590
591 public XTN[] getPhone() {
592 XTN[] retVal = this.getTypedField(12, new XTN[0]);
593 return retVal;
594 }
595
596
597
598
599
600 public XTN[] getRol12_Phone() {
601 XTN[] retVal = this.getTypedField(12, new XTN[0]);
602 return retVal;
603 }
604
605
606
607
608
609
610
611 public int getPhoneReps() {
612 return this.getReps(12);
613 }
614
615
616
617
618
619
620
621
622 public XTN getPhone(int rep) {
623 XTN retVal = this.getTypedField(12, rep);
624 return retVal;
625 }
626
627
628
629
630
631
632
633 public XTN getRol12_Phone(int rep) {
634 XTN retVal = this.getTypedField(12, rep);
635 return retVal;
636 }
637
638
639
640
641
642
643 public int getRol12_PhoneReps() {
644 return this.getReps(12);
645 }
646
647
648
649
650
651
652
653
654
655 public XTN insertPhone(int rep) throws HL7Exception {
656 return (XTN) super.insertRepetition(12, rep);
657 }
658
659
660
661
662
663
664
665
666
667 public XTN insertRol12_Phone(int rep) throws HL7Exception {
668 return (XTN) super.insertRepetition(12, rep);
669 }
670
671
672
673
674
675
676
677
678
679 public XTN removePhone(int rep) throws HL7Exception {
680 return (XTN) super.removeRepetition(12, rep);
681 }
682
683
684
685
686
687
688
689
690
691 public XTN removeRol12_Phone(int rep) throws HL7Exception {
692 return (XTN) super.removeRepetition(12, rep);
693 }
694
695
696
697
698
699
700
701
702 public PL getPersonSLocation() {
703 PL retVal = this.getTypedField(13, 0);
704 return retVal;
705 }
706
707
708
709
710
711 public PL getRol13_PersonSLocation() {
712 PL retVal = this.getTypedField(13, 0);
713 return retVal;
714 }
715
716
717
718
719
720
721
722 public XON getOrganization() {
723 XON retVal = this.getTypedField(14, 0);
724 return retVal;
725 }
726
727
728
729
730
731 public XON getRol14_Organization() {
732 XON retVal = this.getTypedField(14, 0);
733 return retVal;
734 }
735
736
737
738
739
740
741 protected Type createNewTypeWithoutReflection(int field) {
742 switch (field) {
743 case 0: return new EI(getMessage());
744 case 1: return new ID(getMessage(), new Integer( 206 ));
745 case 2: return new CWE(getMessage());
746 case 3: return new XCN(getMessage());
747 case 4: return new DTM(getMessage());
748 case 5: return new DTM(getMessage());
749 case 6: return new CWE(getMessage());
750 case 7: return new CWE(getMessage());
751 case 8: return new CWE(getMessage());
752 case 9: return new CWE(getMessage());
753 case 10: return new XAD(getMessage());
754 case 11: return new XTN(getMessage());
755 case 12: return new PL(getMessage());
756 case 13: return new XON(getMessage());
757 default: return null;
758 }
759 }
760
761
762 }
763