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.v24.segment;
35
36
37 import ca.uhn.hl7v2.model.v24.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
71
72
73 @SuppressWarnings("unused")
74 public class OBX extends AbstractSegment {
75
76
77
78
79 public OBX(Group parent, ModelClassFactory factory) {
80 super(parent, factory);
81 init(factory);
82 }
83
84 private void init(ModelClassFactory factory) {
85 try {
86 this.add(SI.class, false, 1, 4, new Object[]{ getMessage() }, "Set ID - OBX");
87 this.add(ID.class, false, 1, 2, new Object[]{ getMessage(), new Integer(125) }, "Value Type");
88 this.add(CE.class, true, 1, 250, new Object[]{ getMessage() }, "Observation Identifier");
89 this.add(ST.class, false, 1, 20, new Object[]{ getMessage() }, "Observation Sub-Id");
90 this.add(Varies.class, false, 0, 65536, new Object[]{ getMessage() }, "Observation Value");
91 this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Units");
92 this.add(ST.class, false, 1, 60, new Object[]{ getMessage() }, "References Range");
93 this.add(IS.class, false, 1, 5, new Object[]{ getMessage(), new Integer(78) }, "Abnormal Flags");
94 this.add(NM.class, false, 5, 5, new Object[]{ getMessage() }, "Probability");
95 this.add(ID.class, false, 1, 2, new Object[]{ getMessage(), new Integer(80) }, "Nature of Abnormal Test");
96 this.add(ID.class, true, 1, 1, new Object[]{ getMessage(), new Integer(85) }, "Observation Result Status");
97 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "Date Last Observation Normal Value");
98 this.add(ST.class, false, 1, 20, new Object[]{ getMessage() }, "User Defined Access Checks");
99 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "Date/Time of the Observation");
100 this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Producer's ID");
101 this.add(XCN.class, false, 1, 250, new Object[]{ getMessage() }, "Responsible Observer");
102 this.add(CE.class, false, 0, 250, new Object[]{ getMessage() }, "Observation Method");
103 this.add(EI.class, false, 0, 22, new Object[]{ getMessage() }, "Equipment Instance Identifier");
104 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "Date/Time of the Analysis");
105 } catch(HL7Exception e) {
106 log.error("Unexpected error creating OBX - this is probably a bug in the source code generator.", e);
107 }
108 }
109
110
111
112
113
114
115
116 public SI getSetIDOBX() {
117 SI retVal = this.getTypedField(1, 0);
118 return retVal;
119 }
120
121
122
123
124
125 public SI getObx1_SetIDOBX() {
126 SI retVal = this.getTypedField(1, 0);
127 return retVal;
128 }
129
130
131
132
133
134
135
136 public ID getValueType() {
137 ID retVal = this.getTypedField(2, 0);
138 return retVal;
139 }
140
141
142
143
144
145 public ID getObx2_ValueType() {
146 ID retVal = this.getTypedField(2, 0);
147 return retVal;
148 }
149
150
151
152
153
154
155
156 public CE getObservationIdentifier() {
157 CE retVal = this.getTypedField(3, 0);
158 return retVal;
159 }
160
161
162
163
164
165 public CE getObx3_ObservationIdentifier() {
166 CE retVal = this.getTypedField(3, 0);
167 return retVal;
168 }
169
170
171
172
173
174
175
176 public ST getObservationSubId() {
177 ST retVal = this.getTypedField(4, 0);
178 return retVal;
179 }
180
181
182
183
184
185 public ST getObx4_ObservationSubId() {
186 ST retVal = this.getTypedField(4, 0);
187 return retVal;
188 }
189
190
191
192
193
194 public Varies[] getObservationValue() {
195 Varies[] retVal = this.getTypedField(5, new Varies[0]);
196 return retVal;
197 }
198
199
200
201
202
203 public Varies[] getObx5_ObservationValue() {
204 Varies[] retVal = this.getTypedField(5, new Varies[0]);
205 return retVal;
206 }
207
208
209
210
211
212
213
214 public int getObservationValueReps() {
215 return this.getReps(5);
216 }
217
218
219
220
221
222
223
224
225 public Varies getObservationValue(int rep) {
226 Varies retVal = this.getTypedField(5, rep);
227 return retVal;
228 }
229
230
231
232
233
234
235
236 public Varies getObx5_ObservationValue(int rep) {
237 Varies retVal = this.getTypedField(5, rep);
238 return retVal;
239 }
240
241
242
243
244
245
246 public int getObx5_ObservationValueReps() {
247 return this.getReps(5);
248 }
249
250
251
252
253
254
255
256
257
258 public Varies insertObservationValue(int rep) throws HL7Exception {
259 return (Varies) super.insertRepetition(5, rep);
260 }
261
262
263
264
265
266
267
268
269
270 public Varies insertObx5_ObservationValue(int rep) throws HL7Exception {
271 return (Varies) super.insertRepetition(5, rep);
272 }
273
274
275
276
277
278
279
280
281
282 public Varies removeObservationValue(int rep) throws HL7Exception {
283 return (Varies) super.removeRepetition(5, rep);
284 }
285
286
287
288
289
290
291
292
293
294 public Varies removeObx5_ObservationValue(int rep) throws HL7Exception {
295 return (Varies) super.removeRepetition(5, rep);
296 }
297
298
299
300
301
302
303
304
305 public CE getUnits() {
306 CE retVal = this.getTypedField(6, 0);
307 return retVal;
308 }
309
310
311
312
313
314 public CE getObx6_Units() {
315 CE retVal = this.getTypedField(6, 0);
316 return retVal;
317 }
318
319
320
321
322
323
324
325 public ST getReferencesRange() {
326 ST retVal = this.getTypedField(7, 0);
327 return retVal;
328 }
329
330
331
332
333
334 public ST getObx7_ReferencesRange() {
335 ST retVal = this.getTypedField(7, 0);
336 return retVal;
337 }
338
339
340
341
342
343
344
345 public IS getAbnormalFlags() {
346 IS retVal = this.getTypedField(8, 0);
347 return retVal;
348 }
349
350
351
352
353
354 public IS getObx8_AbnormalFlags() {
355 IS retVal = this.getTypedField(8, 0);
356 return retVal;
357 }
358
359
360
361
362
363 public NM[] getProbability() {
364 NM[] retVal = this.getTypedField(9, new NM[0]);
365 return retVal;
366 }
367
368
369
370
371
372 public NM[] getObx9_Probability() {
373 NM[] retVal = this.getTypedField(9, new NM[0]);
374 return retVal;
375 }
376
377
378
379
380
381
382
383 public int getProbabilityReps() {
384 return this.getReps(9);
385 }
386
387
388
389
390
391
392
393
394 public NM getProbability(int rep) {
395 NM retVal = this.getTypedField(9, rep);
396 return retVal;
397 }
398
399
400
401
402
403
404
405 public NM getObx9_Probability(int rep) {
406 NM retVal = this.getTypedField(9, rep);
407 return retVal;
408 }
409
410
411
412
413
414
415 public int getObx9_ProbabilityReps() {
416 return this.getReps(9);
417 }
418
419
420
421
422
423
424
425
426
427 public NM insertProbability(int rep) throws HL7Exception {
428 return (NM) super.insertRepetition(9, rep);
429 }
430
431
432
433
434
435
436
437
438
439 public NM insertObx9_Probability(int rep) throws HL7Exception {
440 return (NM) super.insertRepetition(9, rep);
441 }
442
443
444
445
446
447
448
449
450
451 public NM removeProbability(int rep) throws HL7Exception {
452 return (NM) super.removeRepetition(9, rep);
453 }
454
455
456
457
458
459
460
461
462
463 public NM removeObx9_Probability(int rep) throws HL7Exception {
464 return (NM) super.removeRepetition(9, rep);
465 }
466
467
468
469
470
471
472
473
474 public ID getNatureOfAbnormalTest() {
475 ID retVal = this.getTypedField(10, 0);
476 return retVal;
477 }
478
479
480
481
482
483 public ID getObx10_NatureOfAbnormalTest() {
484 ID retVal = this.getTypedField(10, 0);
485 return retVal;
486 }
487
488
489
490
491
492
493
494 public ID getObservationResultStatus() {
495 ID retVal = this.getTypedField(11, 0);
496 return retVal;
497 }
498
499
500
501
502
503 public ID getObx11_ObservationResultStatus() {
504 ID retVal = this.getTypedField(11, 0);
505 return retVal;
506 }
507
508
509
510
511
512
513
514 public TS getDateLastObservationNormalValue() {
515 TS retVal = this.getTypedField(12, 0);
516 return retVal;
517 }
518
519
520
521
522
523 public TS getObx12_DateLastObservationNormalValue() {
524 TS retVal = this.getTypedField(12, 0);
525 return retVal;
526 }
527
528
529
530
531
532
533
534 public ST getUserDefinedAccessChecks() {
535 ST retVal = this.getTypedField(13, 0);
536 return retVal;
537 }
538
539
540
541
542
543 public ST getObx13_UserDefinedAccessChecks() {
544 ST retVal = this.getTypedField(13, 0);
545 return retVal;
546 }
547
548
549
550
551
552
553
554 public TS getDateTimeOfTheObservation() {
555 TS retVal = this.getTypedField(14, 0);
556 return retVal;
557 }
558
559
560
561
562
563 public TS getObx14_DateTimeOfTheObservation() {
564 TS retVal = this.getTypedField(14, 0);
565 return retVal;
566 }
567
568
569
570
571
572
573
574 public CE getProducerSID() {
575 CE retVal = this.getTypedField(15, 0);
576 return retVal;
577 }
578
579
580
581
582
583 public CE getObx15_ProducerSID() {
584 CE retVal = this.getTypedField(15, 0);
585 return retVal;
586 }
587
588
589
590
591
592
593
594 public XCN getResponsibleObserver() {
595 XCN retVal = this.getTypedField(16, 0);
596 return retVal;
597 }
598
599
600
601
602
603 public XCN getObx16_ResponsibleObserver() {
604 XCN retVal = this.getTypedField(16, 0);
605 return retVal;
606 }
607
608
609
610
611
612 public CE[] getObservationMethod() {
613 CE[] retVal = this.getTypedField(17, new CE[0]);
614 return retVal;
615 }
616
617
618
619
620
621 public CE[] getObx17_ObservationMethod() {
622 CE[] retVal = this.getTypedField(17, new CE[0]);
623 return retVal;
624 }
625
626
627
628
629
630
631
632 public int getObservationMethodReps() {
633 return this.getReps(17);
634 }
635
636
637
638
639
640
641
642
643 public CE getObservationMethod(int rep) {
644 CE retVal = this.getTypedField(17, rep);
645 return retVal;
646 }
647
648
649
650
651
652
653
654 public CE getObx17_ObservationMethod(int rep) {
655 CE retVal = this.getTypedField(17, rep);
656 return retVal;
657 }
658
659
660
661
662
663
664 public int getObx17_ObservationMethodReps() {
665 return this.getReps(17);
666 }
667
668
669
670
671
672
673
674
675
676 public CE insertObservationMethod(int rep) throws HL7Exception {
677 return (CE) super.insertRepetition(17, rep);
678 }
679
680
681
682
683
684
685
686
687
688 public CE insertObx17_ObservationMethod(int rep) throws HL7Exception {
689 return (CE) super.insertRepetition(17, rep);
690 }
691
692
693
694
695
696
697
698
699
700 public CE removeObservationMethod(int rep) throws HL7Exception {
701 return (CE) super.removeRepetition(17, rep);
702 }
703
704
705
706
707
708
709
710
711
712 public CE removeObx17_ObservationMethod(int rep) throws HL7Exception {
713 return (CE) super.removeRepetition(17, rep);
714 }
715
716
717
718
719
720
721 public EI[] getEquipmentInstanceIdentifier() {
722 EI[] retVal = this.getTypedField(18, new EI[0]);
723 return retVal;
724 }
725
726
727
728
729
730 public EI[] getObx18_EquipmentInstanceIdentifier() {
731 EI[] retVal = this.getTypedField(18, new EI[0]);
732 return retVal;
733 }
734
735
736
737
738
739
740
741 public int getEquipmentInstanceIdentifierReps() {
742 return this.getReps(18);
743 }
744
745
746
747
748
749
750
751
752 public EI getEquipmentInstanceIdentifier(int rep) {
753 EI retVal = this.getTypedField(18, rep);
754 return retVal;
755 }
756
757
758
759
760
761
762
763 public EI getObx18_EquipmentInstanceIdentifier(int rep) {
764 EI retVal = this.getTypedField(18, rep);
765 return retVal;
766 }
767
768
769
770
771
772
773 public int getObx18_EquipmentInstanceIdentifierReps() {
774 return this.getReps(18);
775 }
776
777
778
779
780
781
782
783
784
785 public EI insertEquipmentInstanceIdentifier(int rep) throws HL7Exception {
786 return (EI) super.insertRepetition(18, rep);
787 }
788
789
790
791
792
793
794
795
796
797 public EI insertObx18_EquipmentInstanceIdentifier(int rep) throws HL7Exception {
798 return (EI) super.insertRepetition(18, rep);
799 }
800
801
802
803
804
805
806
807
808
809 public EI removeEquipmentInstanceIdentifier(int rep) throws HL7Exception {
810 return (EI) super.removeRepetition(18, rep);
811 }
812
813
814
815
816
817
818
819
820
821 public EI removeObx18_EquipmentInstanceIdentifier(int rep) throws HL7Exception {
822 return (EI) super.removeRepetition(18, rep);
823 }
824
825
826
827
828
829
830
831
832 public TS getDateTimeOfTheAnalysis() {
833 TS retVal = this.getTypedField(19, 0);
834 return retVal;
835 }
836
837
838
839
840
841 public TS getObx19_DateTimeOfTheAnalysis() {
842 TS retVal = this.getTypedField(19, 0);
843 return retVal;
844 }
845
846
847
848
849
850
851 protected Type createNewTypeWithoutReflection(int field) {
852 switch (field) {
853 case 0: return new SI(getMessage());
854 case 1: return new ID(getMessage(), new Integer( 125 ));
855 case 2: return new CE(getMessage());
856 case 3: return new ST(getMessage());
857 case 4: return new Varies(getMessage());
858 case 5: return new CE(getMessage());
859 case 6: return new ST(getMessage());
860 case 7: return new IS(getMessage(), new Integer( 78 ));
861 case 8: return new NM(getMessage());
862 case 9: return new ID(getMessage(), new Integer( 80 ));
863 case 10: return new ID(getMessage(), new Integer( 85 ));
864 case 11: return new TS(getMessage());
865 case 12: return new ST(getMessage());
866 case 13: return new TS(getMessage());
867 case 14: return new CE(getMessage());
868 case 15: return new XCN(getMessage());
869 case 16: return new CE(getMessage());
870 case 17: return new EI(getMessage());
871 case 18: return new TS(getMessage());
872 default: return null;
873 }
874 }
875
876
877 }
878