View Javadoc
1   /*
2    * This class is an auto-generated source file for a HAPI
3    * HL7 v2.x standard structure class.
4    *
5    * For more information, visit: http://hl7api.sourceforge.net/
6    * 
7    * The contents of this file are subject to the Mozilla Public License Version 1.1 
8    * (the "License"); you may not use this file except in compliance with the License. 
9    * You may obtain a copy of the License at http://www.mozilla.org/MPL/ 
10   * Software distributed under the License is distributed on an "AS IS" basis, 
11   * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the 
12   * specific language governing rights and limitations under the License. 
13   * 
14   * The Original Code is "[file_name]".  Description: 
15   * "[one_line_description]" 
16   * 
17   * The Initial Developer of the Original Code is University Health Network. Copyright (C) 
18   * 2012.  All Rights Reserved. 
19   * 
20   * Contributor(s): ______________________________________. 
21   * 
22   * Alternatively, the contents of this file may be used under the terms of the 
23   * GNU General Public License (the  "GPL"), in which case the provisions of the GPL are 
24   * applicable instead of those above.  If you wish to allow use of your version of this 
25   * file only under the terms of the GPL and not to allow others to use your version 
26   * of this file under the MPL, indicate your decision by deleting  the provisions above 
27   * and replace  them with the notice and other provisions required by the GPL License.  
28   * If you do not delete the provisions above, a recipient may use your version of 
29   * this file under either the MPL or the GPL. 
30   * 
31   */
32  
33  
34  package ca.uhn.hl7v2.model.v24.segment;
35  
36  // import ca.uhn.hl7v2.model.v24.group.*;
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   *<p>Represents an HL7 RXE message segment (Pharmacy/Treatment Encoded Order). 
50   * This segment has the following fields:</p>
51   * <ul>
52       * <li>RXE-1: Quantity/Timing (TQ) <b> </b>
53       * <li>RXE-2: Give Code (CE) <b> </b>
54       * <li>RXE-3: Give Amount - Minimum (NM) <b> </b>
55       * <li>RXE-4: Give Amount - Maximum (NM) <b>optional </b>
56       * <li>RXE-5: Give Units (CE) <b> </b>
57       * <li>RXE-6: Give Dosage Form (CE) <b>optional </b>
58       * <li>RXE-7: Provider's Administration Instructions (CE) <b>optional repeating</b>
59       * <li>RXE-8: Deliver-To Location (LA1) <b>optional </b>
60       * <li>RXE-9: Substitution Status (ID) <b>optional </b>
61       * <li>RXE-10: Dispense Amount (NM) <b>optional </b>
62       * <li>RXE-11: Dispense Units (CE) <b>optional </b>
63       * <li>RXE-12: Number of Refills (NM) <b>optional </b>
64       * <li>RXE-13: Ordering Provider's DEA Number (XCN) <b>optional repeating</b>
65       * <li>RXE-14: Pharmacist/Treatment Supplier's Verifier ID (XCN) <b>optional repeating</b>
66       * <li>RXE-15: Prescription Number (ST) <b>optional </b>
67       * <li>RXE-16: Number of Refills Remaining (NM) <b>optional </b>
68       * <li>RXE-17: Number of Refills/Doses Dispensed (NM) <b>optional </b>
69       * <li>RXE-18: D/T of Most Recent Refill or Dose Dispensed (TS) <b>optional </b>
70       * <li>RXE-19: Total Daily Dose (CQ) <b>optional </b>
71       * <li>RXE-20: Needs Human Review (ID) <b>optional </b>
72       * <li>RXE-21: Pharmacy/Treatment Supplier's Special Dispensing Instructions (CE) <b>optional repeating</b>
73       * <li>RXE-22: Give Per (Time Unit) (ST) <b>optional </b>
74       * <li>RXE-23: Give Rate Amount (ST) <b>optional </b>
75       * <li>RXE-24: Give Rate Units (CE) <b>optional </b>
76       * <li>RXE-25: Give Strength (NM) <b>optional </b>
77       * <li>RXE-26: Give Strength Units (CE) <b>optional </b>
78       * <li>RXE-27: Give Indication (CE) <b>optional repeating</b>
79       * <li>RXE-28: Dispense Package Size (NM) <b>optional </b>
80       * <li>RXE-29: Dispense Package Size Unit (CE) <b>optional </b>
81       * <li>RXE-30: Dispense Package Method (ID) <b>optional </b>
82       * <li>RXE-31: Supplementary Code (CE) <b>optional repeating</b>
83   * </ul>
84   */
85  @SuppressWarnings("unused")
86  public class RXE extends AbstractSegment {
87  
88      /** 
89       * Creates a new RXE segment
90       */
91      public RXE(Group parent, ModelClassFactory factory) {
92         super(parent, factory);
93         init(factory);
94      }
95  
96      private void init(ModelClassFactory factory) {
97         try {
98                                    this.add(TQ.class, true, 1, 200, new Object[]{ getMessage() }, "Quantity/Timing");
99                                    this.add(CE.class, true, 1, 250, new Object[]{ getMessage() }, "Give Code");
100                                   this.add(NM.class, true, 1, 20, new Object[]{ getMessage() }, "Give Amount - Minimum");
101                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Give Amount - Maximum");
102                                   this.add(CE.class, true, 1, 250, new Object[]{ getMessage() }, "Give Units");
103                                   this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Give Dosage Form");
104                                   this.add(CE.class, false, 0, 250, new Object[]{ getMessage() }, "Provider's Administration Instructions");
105                                   this.add(LA1.class, false, 1, 200, new Object[]{ getMessage() }, "Deliver-To Location");
106                                               this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(167) }, "Substitution Status");
107                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Dispense Amount");
108                                   this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Dispense Units");
109                                   this.add(NM.class, false, 1, 3, new Object[]{ getMessage() }, "Number of Refills");
110                                   this.add(XCN.class, false, 0, 250, new Object[]{ getMessage() }, "Ordering Provider's DEA Number");
111                                   this.add(XCN.class, false, 0, 250, new Object[]{ getMessage() }, "Pharmacist/Treatment Supplier's Verifier ID");
112                                   this.add(ST.class, false, 1, 20, new Object[]{ getMessage() }, "Prescription Number");
113                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Number of Refills Remaining");
114                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Number of Refills/Doses Dispensed");
115                                   this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "D/T of Most Recent Refill or Dose Dispensed");
116                                   this.add(CQ.class, false, 1, 10, new Object[]{ getMessage() }, "Total Daily Dose");
117                                               this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(136) }, "Needs Human Review");
118                                   this.add(CE.class, false, 0, 250, new Object[]{ getMessage() }, "Pharmacy/Treatment Supplier's Special Dispensing Instructions");
119                                   this.add(ST.class, false, 1, 20, new Object[]{ getMessage() }, "Give Per (Time Unit)");
120                                   this.add(ST.class, false, 1, 6, new Object[]{ getMessage() }, "Give Rate Amount");
121                                   this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Give Rate Units");
122                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Give Strength");
123                                   this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Give Strength Units");
124                                   this.add(CE.class, false, 0, 250, new Object[]{ getMessage() }, "Give Indication");
125                                   this.add(NM.class, false, 1, 20, new Object[]{ getMessage() }, "Dispense Package Size");
126                                   this.add(CE.class, false, 1, 250, new Object[]{ getMessage() }, "Dispense Package Size Unit");
127                                               this.add(ID.class, false, 1, 2, new Object[]{ getMessage(), new Integer(321) }, "Dispense Package Method");
128                                   this.add(CE.class, false, 0, 250, new Object[]{ getMessage() }, "Supplementary Code");
129        } catch(HL7Exception e) {
130           log.error("Unexpected error creating RXE - this is probably a bug in the source code generator.", e);
131        }
132     }
133 
134 
135 
136     /**
137      * Returns
138      * RXE-1: "Quantity/Timing" - creates it if necessary
139      */
140     public TQ getQuantityTiming() { 
141 		TQ retVal = this.getTypedField(1, 0);
142 		return retVal;
143     }
144     
145     /**
146      * Returns
147      * RXE-1: "Quantity/Timing" - creates it if necessary
148      */
149     public TQ getRxe1_QuantityTiming() { 
150 		TQ retVal = this.getTypedField(1, 0);
151 		return retVal;
152     }
153 
154 
155 
156     /**
157      * Returns
158      * RXE-2: "Give Code" - creates it if necessary
159      */
160     public CE getGiveCode() { 
161 		CE retVal = this.getTypedField(2, 0);
162 		return retVal;
163     }
164     
165     /**
166      * Returns
167      * RXE-2: "Give Code" - creates it if necessary
168      */
169     public CE getRxe2_GiveCode() { 
170 		CE retVal = this.getTypedField(2, 0);
171 		return retVal;
172     }
173 
174 
175 
176     /**
177      * Returns
178      * RXE-3: "Give Amount - Minimum" - creates it if necessary
179      */
180     public NM getGiveAmountMinimum() { 
181 		NM retVal = this.getTypedField(3, 0);
182 		return retVal;
183     }
184     
185     /**
186      * Returns
187      * RXE-3: "Give Amount - Minimum" - creates it if necessary
188      */
189     public NM getRxe3_GiveAmountMinimum() { 
190 		NM retVal = this.getTypedField(3, 0);
191 		return retVal;
192     }
193 
194 
195 
196     /**
197      * Returns
198      * RXE-4: "Give Amount - Maximum" - creates it if necessary
199      */
200     public NM getGiveAmountMaximum() { 
201 		NM retVal = this.getTypedField(4, 0);
202 		return retVal;
203     }
204     
205     /**
206      * Returns
207      * RXE-4: "Give Amount - Maximum" - creates it if necessary
208      */
209     public NM getRxe4_GiveAmountMaximum() { 
210 		NM retVal = this.getTypedField(4, 0);
211 		return retVal;
212     }
213 
214 
215 
216     /**
217      * Returns
218      * RXE-5: "Give Units" - creates it if necessary
219      */
220     public CE getGiveUnits() { 
221 		CE retVal = this.getTypedField(5, 0);
222 		return retVal;
223     }
224     
225     /**
226      * Returns
227      * RXE-5: "Give Units" - creates it if necessary
228      */
229     public CE getRxe5_GiveUnits() { 
230 		CE retVal = this.getTypedField(5, 0);
231 		return retVal;
232     }
233 
234 
235 
236     /**
237      * Returns
238      * RXE-6: "Give Dosage Form" - creates it if necessary
239      */
240     public CE getGiveDosageForm() { 
241 		CE retVal = this.getTypedField(6, 0);
242 		return retVal;
243     }
244     
245     /**
246      * Returns
247      * RXE-6: "Give Dosage Form" - creates it if necessary
248      */
249     public CE getRxe6_GiveDosageForm() { 
250 		CE retVal = this.getTypedField(6, 0);
251 		return retVal;
252     }
253 
254 
255     /**
256      * Returns all repetitions of Provider's Administration Instructions (RXE-7).
257      */
258     public CE[] getProviderSAdministrationInstructions() {
259     	CE[] retVal = this.getTypedField(7, new CE[0]);
260     	return retVal;
261     }
262 
263 
264     /**
265      * Returns all repetitions of Provider's Administration Instructions (RXE-7).
266      */
267     public CE[] getRxe7_ProviderSAdministrationInstructions() {
268     	CE[] retVal = this.getTypedField(7, new CE[0]);
269     	return retVal;
270     }
271 
272 
273     /**
274      * Returns a count of the current number of repetitions of Provider's Administration Instructions (RXE-7).
275      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
276      * it will return zero.
277      */
278     public int getProviderSAdministrationInstructionsReps() {
279     	return this.getReps(7);
280     }
281 
282 
283     /**
284      * Returns a specific repetition of
285      * RXE-7: "Provider's Administration Instructions" - creates it if necessary
286      *
287      * @param rep The repetition index (0-indexed)
288      */
289     public CE getProviderSAdministrationInstructions(int rep) { 
290 		CE retVal = this.getTypedField(7, rep);
291 		return retVal;
292     }
293 
294     /**
295      * Returns a specific repetition of
296      * RXE-7: "Provider's Administration Instructions" - creates it if necessary
297      *
298      * @param rep The repetition index (0-indexed)
299      */
300     public CE getRxe7_ProviderSAdministrationInstructions(int rep) { 
301 		CE retVal = this.getTypedField(7, rep);
302 		return retVal;
303     }
304 
305     /**
306      * Returns a count of the current number of repetitions of Provider's Administration Instructions (RXE-7).
307      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
308      * it will return zero.
309      */
310     public int getRxe7_ProviderSAdministrationInstructionsReps() {
311     	return this.getReps(7);
312     }
313 
314 
315     /**
316      * Inserts a repetition of
317      * RXE-7: "Provider's Administration Instructions" at a specific index
318      *
319      * @param rep The repetition index (0-indexed)
320      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
321      */
322     public CE insertProviderSAdministrationInstructions(int rep) throws HL7Exception { 
323         return (CE) super.insertRepetition(7, rep);
324     }
325 
326 
327     /**
328      * Inserts a repetition of
329      * RXE-7: "Provider's Administration Instructions" at a specific index
330      *
331      * @param rep The repetition index (0-indexed)
332      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
333      */
334     public CE insertRxe7_ProviderSAdministrationInstructions(int rep) throws HL7Exception { 
335         return (CE) super.insertRepetition(7, rep);
336     }
337 
338 
339     /**
340      * Removes a repetition of
341      * RXE-7: "Provider's Administration Instructions" at a specific index
342      *
343      * @param rep The repetition index (0-indexed)
344      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
345      */
346     public CE removeProviderSAdministrationInstructions(int rep) throws HL7Exception { 
347         return (CE) super.removeRepetition(7, rep);
348     }
349 
350 
351     /**
352      * Removes a repetition of
353      * RXE-7: "Provider's Administration Instructions" at a specific index
354      *
355      * @param rep The repetition index (0-indexed)
356      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
357      */
358     public CE removeRxe7_ProviderSAdministrationInstructions(int rep) throws HL7Exception { 
359         return (CE) super.removeRepetition(7, rep);
360     }
361 
362 
363 
364 
365     /**
366      * Returns
367      * RXE-8: "Deliver-To Location" - creates it if necessary
368      */
369     public LA1 getDeliverToLocation() { 
370 		LA1 retVal = this.getTypedField(8, 0);
371 		return retVal;
372     }
373     
374     /**
375      * Returns
376      * RXE-8: "Deliver-To Location" - creates it if necessary
377      */
378     public LA1 getRxe8_DeliverToLocation() { 
379 		LA1 retVal = this.getTypedField(8, 0);
380 		return retVal;
381     }
382 
383 
384 
385     /**
386      * Returns
387      * RXE-9: "Substitution Status" - creates it if necessary
388      */
389     public ID getSubstitutionStatus() { 
390 		ID retVal = this.getTypedField(9, 0);
391 		return retVal;
392     }
393     
394     /**
395      * Returns
396      * RXE-9: "Substitution Status" - creates it if necessary
397      */
398     public ID getRxe9_SubstitutionStatus() { 
399 		ID retVal = this.getTypedField(9, 0);
400 		return retVal;
401     }
402 
403 
404 
405     /**
406      * Returns
407      * RXE-10: "Dispense Amount" - creates it if necessary
408      */
409     public NM getDispenseAmount() { 
410 		NM retVal = this.getTypedField(10, 0);
411 		return retVal;
412     }
413     
414     /**
415      * Returns
416      * RXE-10: "Dispense Amount" - creates it if necessary
417      */
418     public NM getRxe10_DispenseAmount() { 
419 		NM retVal = this.getTypedField(10, 0);
420 		return retVal;
421     }
422 
423 
424 
425     /**
426      * Returns
427      * RXE-11: "Dispense Units" - creates it if necessary
428      */
429     public CE getDispenseUnits() { 
430 		CE retVal = this.getTypedField(11, 0);
431 		return retVal;
432     }
433     
434     /**
435      * Returns
436      * RXE-11: "Dispense Units" - creates it if necessary
437      */
438     public CE getRxe11_DispenseUnits() { 
439 		CE retVal = this.getTypedField(11, 0);
440 		return retVal;
441     }
442 
443 
444 
445     /**
446      * Returns
447      * RXE-12: "Number of Refills" - creates it if necessary
448      */
449     public NM getNumberOfRefills() { 
450 		NM retVal = this.getTypedField(12, 0);
451 		return retVal;
452     }
453     
454     /**
455      * Returns
456      * RXE-12: "Number of Refills" - creates it if necessary
457      */
458     public NM getRxe12_NumberOfRefills() { 
459 		NM retVal = this.getTypedField(12, 0);
460 		return retVal;
461     }
462 
463 
464     /**
465      * Returns all repetitions of Ordering Provider's DEA Number (RXE-13).
466      */
467     public XCN[] getOrderingProviderSDEANumber() {
468     	XCN[] retVal = this.getTypedField(13, new XCN[0]);
469     	return retVal;
470     }
471 
472 
473     /**
474      * Returns all repetitions of Ordering Provider's DEA Number (RXE-13).
475      */
476     public XCN[] getRxe13_OrderingProviderSDEANumber() {
477     	XCN[] retVal = this.getTypedField(13, new XCN[0]);
478     	return retVal;
479     }
480 
481 
482     /**
483      * Returns a count of the current number of repetitions of Ordering Provider's DEA Number (RXE-13).
484      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
485      * it will return zero.
486      */
487     public int getOrderingProviderSDEANumberReps() {
488     	return this.getReps(13);
489     }
490 
491 
492     /**
493      * Returns a specific repetition of
494      * RXE-13: "Ordering Provider's DEA Number" - creates it if necessary
495      *
496      * @param rep The repetition index (0-indexed)
497      */
498     public XCN getOrderingProviderSDEANumber(int rep) { 
499 		XCN retVal = this.getTypedField(13, rep);
500 		return retVal;
501     }
502 
503     /**
504      * Returns a specific repetition of
505      * RXE-13: "Ordering Provider's DEA Number" - creates it if necessary
506      *
507      * @param rep The repetition index (0-indexed)
508      */
509     public XCN getRxe13_OrderingProviderSDEANumber(int rep) { 
510 		XCN retVal = this.getTypedField(13, rep);
511 		return retVal;
512     }
513 
514     /**
515      * Returns a count of the current number of repetitions of Ordering Provider's DEA Number (RXE-13).
516      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
517      * it will return zero.
518      */
519     public int getRxe13_OrderingProviderSDEANumberReps() {
520     	return this.getReps(13);
521     }
522 
523 
524     /**
525      * Inserts a repetition of
526      * RXE-13: "Ordering Provider's DEA Number" at a specific index
527      *
528      * @param rep The repetition index (0-indexed)
529      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
530      */
531     public XCN insertOrderingProviderSDEANumber(int rep) throws HL7Exception { 
532         return (XCN) super.insertRepetition(13, rep);
533     }
534 
535 
536     /**
537      * Inserts a repetition of
538      * RXE-13: "Ordering Provider's DEA Number" at a specific index
539      *
540      * @param rep The repetition index (0-indexed)
541      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
542      */
543     public XCN insertRxe13_OrderingProviderSDEANumber(int rep) throws HL7Exception { 
544         return (XCN) super.insertRepetition(13, rep);
545     }
546 
547 
548     /**
549      * Removes a repetition of
550      * RXE-13: "Ordering Provider's DEA Number" at a specific index
551      *
552      * @param rep The repetition index (0-indexed)
553      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
554      */
555     public XCN removeOrderingProviderSDEANumber(int rep) throws HL7Exception { 
556         return (XCN) super.removeRepetition(13, rep);
557     }
558 
559 
560     /**
561      * Removes a repetition of
562      * RXE-13: "Ordering Provider's DEA Number" at a specific index
563      *
564      * @param rep The repetition index (0-indexed)
565      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
566      */
567     public XCN removeRxe13_OrderingProviderSDEANumber(int rep) throws HL7Exception { 
568         return (XCN) super.removeRepetition(13, rep);
569     }
570 
571 
572 
573     /**
574      * Returns all repetitions of Pharmacist/Treatment Supplier's Verifier ID (RXE-14).
575      */
576     public XCN[] getPharmacistTreatmentSupplierSVerifierID() {
577     	XCN[] retVal = this.getTypedField(14, new XCN[0]);
578     	return retVal;
579     }
580 
581 
582     /**
583      * Returns all repetitions of Pharmacist/Treatment Supplier's Verifier ID (RXE-14).
584      */
585     public XCN[] getRxe14_PharmacistTreatmentSupplierSVerifierID() {
586     	XCN[] retVal = this.getTypedField(14, new XCN[0]);
587     	return retVal;
588     }
589 
590 
591     /**
592      * Returns a count of the current number of repetitions of Pharmacist/Treatment Supplier's Verifier ID (RXE-14).
593      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
594      * it will return zero.
595      */
596     public int getPharmacistTreatmentSupplierSVerifierIDReps() {
597     	return this.getReps(14);
598     }
599 
600 
601     /**
602      * Returns a specific repetition of
603      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" - creates it if necessary
604      *
605      * @param rep The repetition index (0-indexed)
606      */
607     public XCN getPharmacistTreatmentSupplierSVerifierID(int rep) { 
608 		XCN retVal = this.getTypedField(14, rep);
609 		return retVal;
610     }
611 
612     /**
613      * Returns a specific repetition of
614      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" - creates it if necessary
615      *
616      * @param rep The repetition index (0-indexed)
617      */
618     public XCN getRxe14_PharmacistTreatmentSupplierSVerifierID(int rep) { 
619 		XCN retVal = this.getTypedField(14, rep);
620 		return retVal;
621     }
622 
623     /**
624      * Returns a count of the current number of repetitions of Pharmacist/Treatment Supplier's Verifier ID (RXE-14).
625      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
626      * it will return zero.
627      */
628     public int getRxe14_PharmacistTreatmentSupplierSVerifierIDReps() {
629     	return this.getReps(14);
630     }
631 
632 
633     /**
634      * Inserts a repetition of
635      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" at a specific index
636      *
637      * @param rep The repetition index (0-indexed)
638      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
639      */
640     public XCN insertPharmacistTreatmentSupplierSVerifierID(int rep) throws HL7Exception { 
641         return (XCN) super.insertRepetition(14, rep);
642     }
643 
644 
645     /**
646      * Inserts a repetition of
647      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" at a specific index
648      *
649      * @param rep The repetition index (0-indexed)
650      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
651      */
652     public XCN insertRxe14_PharmacistTreatmentSupplierSVerifierID(int rep) throws HL7Exception { 
653         return (XCN) super.insertRepetition(14, rep);
654     }
655 
656 
657     /**
658      * Removes a repetition of
659      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" at a specific index
660      *
661      * @param rep The repetition index (0-indexed)
662      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
663      */
664     public XCN removePharmacistTreatmentSupplierSVerifierID(int rep) throws HL7Exception { 
665         return (XCN) super.removeRepetition(14, rep);
666     }
667 
668 
669     /**
670      * Removes a repetition of
671      * RXE-14: "Pharmacist/Treatment Supplier's Verifier ID" at a specific index
672      *
673      * @param rep The repetition index (0-indexed)
674      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
675      */
676     public XCN removeRxe14_PharmacistTreatmentSupplierSVerifierID(int rep) throws HL7Exception { 
677         return (XCN) super.removeRepetition(14, rep);
678     }
679 
680 
681 
682 
683     /**
684      * Returns
685      * RXE-15: "Prescription Number" - creates it if necessary
686      */
687     public ST getPrescriptionNumber() { 
688 		ST retVal = this.getTypedField(15, 0);
689 		return retVal;
690     }
691     
692     /**
693      * Returns
694      * RXE-15: "Prescription Number" - creates it if necessary
695      */
696     public ST getRxe15_PrescriptionNumber() { 
697 		ST retVal = this.getTypedField(15, 0);
698 		return retVal;
699     }
700 
701 
702 
703     /**
704      * Returns
705      * RXE-16: "Number of Refills Remaining" - creates it if necessary
706      */
707     public NM getNumberOfRefillsRemaining() { 
708 		NM retVal = this.getTypedField(16, 0);
709 		return retVal;
710     }
711     
712     /**
713      * Returns
714      * RXE-16: "Number of Refills Remaining" - creates it if necessary
715      */
716     public NM getRxe16_NumberOfRefillsRemaining() { 
717 		NM retVal = this.getTypedField(16, 0);
718 		return retVal;
719     }
720 
721 
722 
723     /**
724      * Returns
725      * RXE-17: "Number of Refills/Doses Dispensed" - creates it if necessary
726      */
727     public NM getNumberOfRefillsDosesDispensed() { 
728 		NM retVal = this.getTypedField(17, 0);
729 		return retVal;
730     }
731     
732     /**
733      * Returns
734      * RXE-17: "Number of Refills/Doses Dispensed" - creates it if necessary
735      */
736     public NM getRxe17_NumberOfRefillsDosesDispensed() { 
737 		NM retVal = this.getTypedField(17, 0);
738 		return retVal;
739     }
740 
741 
742 
743     /**
744      * Returns
745      * RXE-18: "D/T of Most Recent Refill or Dose Dispensed" - creates it if necessary
746      */
747     public TS getDTOfMostRecentRefillOrDoseDispensed() { 
748 		TS retVal = this.getTypedField(18, 0);
749 		return retVal;
750     }
751     
752     /**
753      * Returns
754      * RXE-18: "D/T of Most Recent Refill or Dose Dispensed" - creates it if necessary
755      */
756     public TS getRxe18_DTOfMostRecentRefillOrDoseDispensed() { 
757 		TS retVal = this.getTypedField(18, 0);
758 		return retVal;
759     }
760 
761 
762 
763     /**
764      * Returns
765      * RXE-19: "Total Daily Dose" - creates it if necessary
766      */
767     public CQ getTotalDailyDose() { 
768 		CQ retVal = this.getTypedField(19, 0);
769 		return retVal;
770     }
771     
772     /**
773      * Returns
774      * RXE-19: "Total Daily Dose" - creates it if necessary
775      */
776     public CQ getRxe19_TotalDailyDose() { 
777 		CQ retVal = this.getTypedField(19, 0);
778 		return retVal;
779     }
780 
781 
782 
783     /**
784      * Returns
785      * RXE-20: "Needs Human Review" - creates it if necessary
786      */
787     public ID getNeedsHumanReview() { 
788 		ID retVal = this.getTypedField(20, 0);
789 		return retVal;
790     }
791     
792     /**
793      * Returns
794      * RXE-20: "Needs Human Review" - creates it if necessary
795      */
796     public ID getRxe20_NeedsHumanReview() { 
797 		ID retVal = this.getTypedField(20, 0);
798 		return retVal;
799     }
800 
801 
802     /**
803      * Returns all repetitions of Pharmacy/Treatment Supplier's Special Dispensing Instructions (RXE-21).
804      */
805     public CE[] getPharmacyTreatmentSupplierSSpecialDispensingInstructions() {
806     	CE[] retVal = this.getTypedField(21, new CE[0]);
807     	return retVal;
808     }
809 
810 
811     /**
812      * Returns all repetitions of Pharmacy/Treatment Supplier's Special Dispensing Instructions (RXE-21).
813      */
814     public CE[] getRxe21_PharmacyTreatmentSupplierSSpecialDispensingInstructions() {
815     	CE[] retVal = this.getTypedField(21, new CE[0]);
816     	return retVal;
817     }
818 
819 
820     /**
821      * Returns a count of the current number of repetitions of Pharmacy/Treatment Supplier's Special Dispensing Instructions (RXE-21).
822      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
823      * it will return zero.
824      */
825     public int getPharmacyTreatmentSupplierSSpecialDispensingInstructionsReps() {
826     	return this.getReps(21);
827     }
828 
829 
830     /**
831      * Returns a specific repetition of
832      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" - creates it if necessary
833      *
834      * @param rep The repetition index (0-indexed)
835      */
836     public CE getPharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) { 
837 		CE retVal = this.getTypedField(21, rep);
838 		return retVal;
839     }
840 
841     /**
842      * Returns a specific repetition of
843      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" - creates it if necessary
844      *
845      * @param rep The repetition index (0-indexed)
846      */
847     public CE getRxe21_PharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) { 
848 		CE retVal = this.getTypedField(21, rep);
849 		return retVal;
850     }
851 
852     /**
853      * Returns a count of the current number of repetitions of Pharmacy/Treatment Supplier's Special Dispensing Instructions (RXE-21).
854      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
855      * it will return zero.
856      */
857     public int getRxe21_PharmacyTreatmentSupplierSSpecialDispensingInstructionsReps() {
858     	return this.getReps(21);
859     }
860 
861 
862     /**
863      * Inserts a repetition of
864      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" at a specific index
865      *
866      * @param rep The repetition index (0-indexed)
867      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
868      */
869     public CE insertPharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) throws HL7Exception { 
870         return (CE) super.insertRepetition(21, rep);
871     }
872 
873 
874     /**
875      * Inserts a repetition of
876      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" at a specific index
877      *
878      * @param rep The repetition index (0-indexed)
879      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
880      */
881     public CE insertRxe21_PharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) throws HL7Exception { 
882         return (CE) super.insertRepetition(21, rep);
883     }
884 
885 
886     /**
887      * Removes a repetition of
888      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" at a specific index
889      *
890      * @param rep The repetition index (0-indexed)
891      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
892      */
893     public CE removePharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) throws HL7Exception { 
894         return (CE) super.removeRepetition(21, rep);
895     }
896 
897 
898     /**
899      * Removes a repetition of
900      * RXE-21: "Pharmacy/Treatment Supplier's Special Dispensing Instructions" at a specific index
901      *
902      * @param rep The repetition index (0-indexed)
903      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
904      */
905     public CE removeRxe21_PharmacyTreatmentSupplierSSpecialDispensingInstructions(int rep) throws HL7Exception { 
906         return (CE) super.removeRepetition(21, rep);
907     }
908 
909 
910 
911 
912     /**
913      * Returns
914      * RXE-22: "Give Per (Time Unit)" - creates it if necessary
915      */
916     public ST getGivePerTimeUnit() { 
917 		ST retVal = this.getTypedField(22, 0);
918 		return retVal;
919     }
920     
921     /**
922      * Returns
923      * RXE-22: "Give Per (Time Unit)" - creates it if necessary
924      */
925     public ST getRxe22_GivePerTimeUnit() { 
926 		ST retVal = this.getTypedField(22, 0);
927 		return retVal;
928     }
929 
930 
931 
932     /**
933      * Returns
934      * RXE-23: "Give Rate Amount" - creates it if necessary
935      */
936     public ST getGiveRateAmount() { 
937 		ST retVal = this.getTypedField(23, 0);
938 		return retVal;
939     }
940     
941     /**
942      * Returns
943      * RXE-23: "Give Rate Amount" - creates it if necessary
944      */
945     public ST getRxe23_GiveRateAmount() { 
946 		ST retVal = this.getTypedField(23, 0);
947 		return retVal;
948     }
949 
950 
951 
952     /**
953      * Returns
954      * RXE-24: "Give Rate Units" - creates it if necessary
955      */
956     public CE getGiveRateUnits() { 
957 		CE retVal = this.getTypedField(24, 0);
958 		return retVal;
959     }
960     
961     /**
962      * Returns
963      * RXE-24: "Give Rate Units" - creates it if necessary
964      */
965     public CE getRxe24_GiveRateUnits() { 
966 		CE retVal = this.getTypedField(24, 0);
967 		return retVal;
968     }
969 
970 
971 
972     /**
973      * Returns
974      * RXE-25: "Give Strength" - creates it if necessary
975      */
976     public NM getGiveStrength() { 
977 		NM retVal = this.getTypedField(25, 0);
978 		return retVal;
979     }
980     
981     /**
982      * Returns
983      * RXE-25: "Give Strength" - creates it if necessary
984      */
985     public NM getRxe25_GiveStrength() { 
986 		NM retVal = this.getTypedField(25, 0);
987 		return retVal;
988     }
989 
990 
991 
992     /**
993      * Returns
994      * RXE-26: "Give Strength Units" - creates it if necessary
995      */
996     public CE getGiveStrengthUnits() { 
997 		CE retVal = this.getTypedField(26, 0);
998 		return retVal;
999     }
1000     
1001     /**
1002      * Returns
1003      * RXE-26: "Give Strength Units" - creates it if necessary
1004      */
1005     public CE getRxe26_GiveStrengthUnits() { 
1006 		CE retVal = this.getTypedField(26, 0);
1007 		return retVal;
1008     }
1009 
1010 
1011     /**
1012      * Returns all repetitions of Give Indication (RXE-27).
1013      */
1014     public CE[] getGiveIndication() {
1015     	CE[] retVal = this.getTypedField(27, new CE[0]);
1016     	return retVal;
1017     }
1018 
1019 
1020     /**
1021      * Returns all repetitions of Give Indication (RXE-27).
1022      */
1023     public CE[] getRxe27_GiveIndication() {
1024     	CE[] retVal = this.getTypedField(27, new CE[0]);
1025     	return retVal;
1026     }
1027 
1028 
1029     /**
1030      * Returns a count of the current number of repetitions of Give Indication (RXE-27).
1031      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1032      * it will return zero.
1033      */
1034     public int getGiveIndicationReps() {
1035     	return this.getReps(27);
1036     }
1037 
1038 
1039     /**
1040      * Returns a specific repetition of
1041      * RXE-27: "Give Indication" - creates it if necessary
1042      *
1043      * @param rep The repetition index (0-indexed)
1044      */
1045     public CE getGiveIndication(int rep) { 
1046 		CE retVal = this.getTypedField(27, rep);
1047 		return retVal;
1048     }
1049 
1050     /**
1051      * Returns a specific repetition of
1052      * RXE-27: "Give Indication" - creates it if necessary
1053      *
1054      * @param rep The repetition index (0-indexed)
1055      */
1056     public CE getRxe27_GiveIndication(int rep) { 
1057 		CE retVal = this.getTypedField(27, rep);
1058 		return retVal;
1059     }
1060 
1061     /**
1062      * Returns a count of the current number of repetitions of Give Indication (RXE-27).
1063      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1064      * it will return zero.
1065      */
1066     public int getRxe27_GiveIndicationReps() {
1067     	return this.getReps(27);
1068     }
1069 
1070 
1071     /**
1072      * Inserts a repetition of
1073      * RXE-27: "Give Indication" at a specific index
1074      *
1075      * @param rep The repetition index (0-indexed)
1076      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1077      */
1078     public CE insertGiveIndication(int rep) throws HL7Exception { 
1079         return (CE) super.insertRepetition(27, rep);
1080     }
1081 
1082 
1083     /**
1084      * Inserts a repetition of
1085      * RXE-27: "Give Indication" at a specific index
1086      *
1087      * @param rep The repetition index (0-indexed)
1088      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1089      */
1090     public CE insertRxe27_GiveIndication(int rep) throws HL7Exception { 
1091         return (CE) super.insertRepetition(27, rep);
1092     }
1093 
1094 
1095     /**
1096      * Removes a repetition of
1097      * RXE-27: "Give Indication" at a specific index
1098      *
1099      * @param rep The repetition index (0-indexed)
1100      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1101      */
1102     public CE removeGiveIndication(int rep) throws HL7Exception { 
1103         return (CE) super.removeRepetition(27, rep);
1104     }
1105 
1106 
1107     /**
1108      * Removes a repetition of
1109      * RXE-27: "Give Indication" at a specific index
1110      *
1111      * @param rep The repetition index (0-indexed)
1112      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1113      */
1114     public CE removeRxe27_GiveIndication(int rep) throws HL7Exception { 
1115         return (CE) super.removeRepetition(27, rep);
1116     }
1117 
1118 
1119 
1120 
1121     /**
1122      * Returns
1123      * RXE-28: "Dispense Package Size" - creates it if necessary
1124      */
1125     public NM getDispensePackageSize() { 
1126 		NM retVal = this.getTypedField(28, 0);
1127 		return retVal;
1128     }
1129     
1130     /**
1131      * Returns
1132      * RXE-28: "Dispense Package Size" - creates it if necessary
1133      */
1134     public NM getRxe28_DispensePackageSize() { 
1135 		NM retVal = this.getTypedField(28, 0);
1136 		return retVal;
1137     }
1138 
1139 
1140 
1141     /**
1142      * Returns
1143      * RXE-29: "Dispense Package Size Unit" - creates it if necessary
1144      */
1145     public CE getDispensePackageSizeUnit() { 
1146 		CE retVal = this.getTypedField(29, 0);
1147 		return retVal;
1148     }
1149     
1150     /**
1151      * Returns
1152      * RXE-29: "Dispense Package Size Unit" - creates it if necessary
1153      */
1154     public CE getRxe29_DispensePackageSizeUnit() { 
1155 		CE retVal = this.getTypedField(29, 0);
1156 		return retVal;
1157     }
1158 
1159 
1160 
1161     /**
1162      * Returns
1163      * RXE-30: "Dispense Package Method" - creates it if necessary
1164      */
1165     public ID getDispensePackageMethod() { 
1166 		ID retVal = this.getTypedField(30, 0);
1167 		return retVal;
1168     }
1169     
1170     /**
1171      * Returns
1172      * RXE-30: "Dispense Package Method" - creates it if necessary
1173      */
1174     public ID getRxe30_DispensePackageMethod() { 
1175 		ID retVal = this.getTypedField(30, 0);
1176 		return retVal;
1177     }
1178 
1179 
1180     /**
1181      * Returns all repetitions of Supplementary Code (RXE-31).
1182      */
1183     public CE[] getSupplementaryCode() {
1184     	CE[] retVal = this.getTypedField(31, new CE[0]);
1185     	return retVal;
1186     }
1187 
1188 
1189     /**
1190      * Returns all repetitions of Supplementary Code (RXE-31).
1191      */
1192     public CE[] getRxe31_SupplementaryCode() {
1193     	CE[] retVal = this.getTypedField(31, new CE[0]);
1194     	return retVal;
1195     }
1196 
1197 
1198     /**
1199      * Returns a count of the current number of repetitions of Supplementary Code (RXE-31).
1200      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1201      * it will return zero.
1202      */
1203     public int getSupplementaryCodeReps() {
1204     	return this.getReps(31);
1205     }
1206 
1207 
1208     /**
1209      * Returns a specific repetition of
1210      * RXE-31: "Supplementary Code" - creates it if necessary
1211      *
1212      * @param rep The repetition index (0-indexed)
1213      */
1214     public CE getSupplementaryCode(int rep) { 
1215 		CE retVal = this.getTypedField(31, rep);
1216 		return retVal;
1217     }
1218 
1219     /**
1220      * Returns a specific repetition of
1221      * RXE-31: "Supplementary Code" - creates it if necessary
1222      *
1223      * @param rep The repetition index (0-indexed)
1224      */
1225     public CE getRxe31_SupplementaryCode(int rep) { 
1226 		CE retVal = this.getTypedField(31, rep);
1227 		return retVal;
1228     }
1229 
1230     /**
1231      * Returns a count of the current number of repetitions of Supplementary Code (RXE-31).
1232      * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1233      * it will return zero.
1234      */
1235     public int getRxe31_SupplementaryCodeReps() {
1236     	return this.getReps(31);
1237     }
1238 
1239 
1240     /**
1241      * Inserts a repetition of
1242      * RXE-31: "Supplementary Code" at a specific index
1243      *
1244      * @param rep The repetition index (0-indexed)
1245      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1246      */
1247     public CE insertSupplementaryCode(int rep) throws HL7Exception { 
1248         return (CE) super.insertRepetition(31, rep);
1249     }
1250 
1251 
1252     /**
1253      * Inserts a repetition of
1254      * RXE-31: "Supplementary Code" at a specific index
1255      *
1256      * @param rep The repetition index (0-indexed)
1257      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1258      */
1259     public CE insertRxe31_SupplementaryCode(int rep) throws HL7Exception { 
1260         return (CE) super.insertRepetition(31, rep);
1261     }
1262 
1263 
1264     /**
1265      * Removes a repetition of
1266      * RXE-31: "Supplementary Code" at a specific index
1267      *
1268      * @param rep The repetition index (0-indexed)
1269      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1270      */
1271     public CE removeSupplementaryCode(int rep) throws HL7Exception { 
1272         return (CE) super.removeRepetition(31, rep);
1273     }
1274 
1275 
1276     /**
1277      * Removes a repetition of
1278      * RXE-31: "Supplementary Code" at a specific index
1279      *
1280      * @param rep The repetition index (0-indexed)
1281      * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1282      */
1283     public CE removeRxe31_SupplementaryCode(int rep) throws HL7Exception { 
1284         return (CE) super.removeRepetition(31, rep);
1285     }
1286 
1287 
1288 
1289 
1290 
1291 
1292     /** {@inheritDoc} */   
1293     protected Type createNewTypeWithoutReflection(int field) {
1294        switch (field) {
1295           case 0: return new TQ(getMessage());
1296           case 1: return new CE(getMessage());
1297           case 2: return new NM(getMessage());
1298           case 3: return new NM(getMessage());
1299           case 4: return new CE(getMessage());
1300           case 5: return new CE(getMessage());
1301           case 6: return new CE(getMessage());
1302           case 7: return new LA1(getMessage());
1303           case 8: return new ID(getMessage(), new Integer( 167 ));
1304           case 9: return new NM(getMessage());
1305           case 10: return new CE(getMessage());
1306           case 11: return new NM(getMessage());
1307           case 12: return new XCN(getMessage());
1308           case 13: return new XCN(getMessage());
1309           case 14: return new ST(getMessage());
1310           case 15: return new NM(getMessage());
1311           case 16: return new NM(getMessage());
1312           case 17: return new TS(getMessage());
1313           case 18: return new CQ(getMessage());
1314           case 19: return new ID(getMessage(), new Integer( 136 ));
1315           case 20: return new CE(getMessage());
1316           case 21: return new ST(getMessage());
1317           case 22: return new ST(getMessage());
1318           case 23: return new CE(getMessage());
1319           case 24: return new NM(getMessage());
1320           case 25: return new CE(getMessage());
1321           case 26: return new CE(getMessage());
1322           case 27: return new NM(getMessage());
1323           case 28: return new CE(getMessage());
1324           case 29: return new ID(getMessage(), new Integer( 321 ));
1325           case 30: return new CE(getMessage());
1326           default: return null;
1327        }
1328    }
1329 
1330 
1331 }
1332