001    /*
002     * This class is an auto-generated source file for a HAPI
003     * HL7 v2.x standard structure class.
004     *
005     * For more information, visit: http://hl7api.sourceforge.net/
006     */
007    
008    package ca.uhn.hl7v2.model.v24.segment;
009    
010    // import ca.uhn.hl7v2.model.v24.group.*;
011    import ca.uhn.hl7v2.model.v24.datatype.*;
012    import ca.uhn.log.HapiLogFactory;
013    import ca.uhn.hl7v2.HL7Exception;
014    import ca.uhn.hl7v2.parser.ModelClassFactory;
015    import ca.uhn.hl7v2.parser.DefaultModelClassFactory;
016    import ca.uhn.hl7v2.model.AbstractMessage;
017    import ca.uhn.hl7v2.model.Group;
018    import ca.uhn.hl7v2.model.Type;
019    import ca.uhn.hl7v2.model.AbstractSegment;
020    import ca.uhn.hl7v2.model.Varies;
021    
022    /**
023     *<p>Represents an HL7 CDM message segment (Charge Description Master). 
024     * This segment has the following fields:</p>
025     * <ul>
026         * <li>CDM-1: Primary Key Value - CDM (CE) <b> </b>
027         * <li>CDM-2: Charge Code Alias (CE) <b>optional repeating</b>
028         * <li>CDM-3: Charge Description Short (ST) <b> </b>
029         * <li>CDM-4: Charge Description Long (ST) <b>optional </b>
030         * <li>CDM-5: Description Override Indicator (IS) <b>optional </b>
031         * <li>CDM-6: Exploding Charges (CE) <b>optional repeating</b>
032         * <li>CDM-7: Procedure Code (CE) <b>optional repeating</b>
033         * <li>CDM-8: Active/Inactive Flag (ID) <b>optional </b>
034         * <li>CDM-9: Inventory Number (CE) <b>optional repeating</b>
035         * <li>CDM-10: Resource Load (NM) <b>optional </b>
036         * <li>CDM-11: Contract Number (CK) <b>optional repeating</b>
037         * <li>CDM-12: Contract Organization (XON) <b>optional repeating</b>
038         * <li>CDM-13: Room Fee Indicator (ID) <b>optional </b>
039     * </ul>
040     */
041    public class CDM extends AbstractSegment {
042    
043        /** 
044         * Creates a new CDM segment
045         */
046        public CDM(Group parent, ModelClassFactory factory) {
047           super(parent, factory);
048           init(factory);
049        }
050    
051        private void init(ModelClassFactory factory) {
052           try {
053                                      this.add(CE.class, true, 1, 250, new Object[]{ getMessage(), new Integer(132) }, "Primary Key Value - CDM");
054                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(9999) }, "Charge Code Alias");
055                                      this.add(ST.class, true, 1, 20, new Object[]{ getMessage(), new Integer(0) }, "Charge Description Short");
056                                      this.add(ST.class, false, 1, 250, new Object[]{ getMessage(), new Integer(0) }, "Charge Description Long");
057                                      this.add(IS.class, false, 1, 1, new Object[]{ getMessage() }, "Description Override Indicator");
058                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(9999) }, "Exploding Charges");
059                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(88) }, "Procedure Code");
060                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Active/Inactive Flag");
061                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(463) }, "Inventory Number");
062                                      this.add(NM.class, false, 1, 12, new Object[]{ getMessage(), new Integer(0) }, "Resource Load");
063                                      this.add(CK.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Contract Number");
064                                      this.add(XON.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Contract Organization");
065                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Room Fee Indicator");
066           } catch(HL7Exception e) {
067              HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected error creating CDM - this is probably a bug in the source code generator.", e);
068           }
069        }
070    
071    
072    
073        /**
074         * Returns
075         * CDM-1: "Primary Key Value - CDM" - creates it if necessary
076         */
077        public CE getPrimaryKeyValueCDM() { 
078            CE ret = null;
079            try {
080                Type t = this.getField(1, 0);
081                ret = (CE)t;
082            } catch (ClassCastException cce) {
083                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
084                throw new RuntimeException(cce);
085            } catch (HL7Exception he) {
086                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
087                throw new RuntimeException(he);
088            }
089            return ret;
090        }
091    
092    
093        /**
094         * Returns
095         * CDM-1: "Primary Key Value - CDM" - creates it if necessary
096         */
097        public CE getCdm1_PrimaryKeyValueCDM() { 
098            CE ret = null;
099            try {
100                Type t = this.getField(1, 0);
101                ret = (CE)t;
102            } catch (ClassCastException cce) {
103                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
104                throw new RuntimeException(cce);
105            } catch (HL7Exception he) {
106                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
107                throw new RuntimeException(he);
108            }
109            return ret;
110        }
111    
112    
113        /**
114         * Returns all repetitions of Charge Code Alias (CDM-2).
115         */
116        public CE[] getChargeCodeAlias() {
117            CE[] ret = null;
118            try {
119                Type[] t = this.getField(2);  
120                ret = new CE[t.length];
121                for (int i = 0; i < ret.length; i++) {
122                    ret[i] = (CE)t[i];
123                }
124            } catch (ClassCastException cce) {
125                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
126                throw new RuntimeException(cce);
127            } catch (HL7Exception he) {
128                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
129                throw new RuntimeException(he);
130            }
131            return ret;
132        }
133    
134    
135        /**
136         * Returns a count of the current number of repetitions of Charge Code Alias (CDM-2).
137         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
138         * it will return zero.
139         */
140        public int getChargeCodeAliasReps() {
141            CE[] ret = null;
142            try {
143                Type[] t = this.getField(2);
144                return t.length;  
145            } catch (ClassCastException cce) {
146                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
147                throw new RuntimeException(cce);
148            } catch (HL7Exception he) {
149                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
150                throw new RuntimeException(he);
151            }
152        }
153    
154    
155        /**
156         * Returns a specific repetition of
157         * CDM-2: "Charge Code Alias" - creates it if necessary
158         *
159         * @param rep The repetition index (0-indexed)
160         */
161        public CE getChargeCodeAlias(int rep) { 
162            CE ret = null;
163            try {
164                Type t = this.getField(2, rep);
165                ret = (CE)t;
166            } catch (ClassCastException cce) {
167                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
168                throw new RuntimeException(cce);
169            } catch (HL7Exception he) {
170                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
171                throw new RuntimeException(he);
172            }
173            return ret;
174        }
175    
176        /**
177         * Returns a specific repetition of
178         * CDM-2: "Charge Code Alias" - creates it if necessary
179         *
180         * @param rep The repetition index (0-indexed)
181         */
182        public CE getCdm2_ChargeCodeAlias(int rep) { 
183            CE ret = null;
184            try {
185                Type t = this.getField(2, rep);
186                ret = (CE)t;
187            } catch (ClassCastException cce) {
188                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
189                throw new RuntimeException(cce);
190            } catch (HL7Exception he) {
191                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
192                throw new RuntimeException(he);
193            }
194            return ret;
195        }
196    
197    
198        /**
199         * Returns a count of the current number of repetitions of Charge Code Alias (CDM-2).
200         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
201         * it will return zero.
202         */
203        public int getCdm2_ChargeCodeAliasReps() {
204            CE[] ret = null;
205            try {
206                Type[] t = this.getField(2);
207                return t.length;  
208            } catch (ClassCastException cce) {
209                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
210                throw new RuntimeException(cce);
211            } catch (HL7Exception he) {
212                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
213                throw new RuntimeException(he);
214            }
215        }
216    
217    
218    
219        /**
220         * Inserts a repetition of
221         * CDM-2: "Charge Code Alias" at a specific index
222         *
223         * @param rep The repetition index (0-indexed)
224         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
225         */
226        public CE insertChargeCodeAlias(int rep) throws HL7Exception { 
227            return (CE) super.insertRepetition(2, rep);
228        }
229    
230    
231    
232        /**
233         * Inserts a repetition of
234         * CDM-2: "Charge Code Alias" at a specific index
235         *
236         * @param rep The repetition index (0-indexed)
237         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
238         */
239        public CE insertCdm2_ChargeCodeAlias(int rep) throws HL7Exception { 
240            return (CE) super.insertRepetition(2, rep);
241        }
242    
243    
244        /**
245         * Removes a repetition of
246         * CDM-2: "Charge Code Alias" at a specific index
247         *
248         * @param rep The repetition index (0-indexed)
249         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
250         */
251        public CE removeChargeCodeAlias(int rep) throws HL7Exception { 
252            return (CE) super.removeRepetition(2, rep);
253        }
254    
255    
256        /**
257         * Removes a repetition of
258         * CDM-2: "Charge Code Alias" at a specific index
259         *
260         * @param rep The repetition index (0-indexed)
261         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
262         */
263        public CE removeCdm2_ChargeCodeAlias(int rep) throws HL7Exception { 
264            return (CE) super.removeRepetition(2, rep);
265        }
266    
267    
268    
269    
270        /**
271         * Returns
272         * CDM-3: "Charge Description Short" - creates it if necessary
273         */
274        public ST getChargeDescriptionShort() { 
275            ST ret = null;
276            try {
277                Type t = this.getField(3, 0);
278                ret = (ST)t;
279            } catch (ClassCastException cce) {
280                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
281                throw new RuntimeException(cce);
282            } catch (HL7Exception he) {
283                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
284                throw new RuntimeException(he);
285            }
286            return ret;
287        }
288    
289    
290        /**
291         * Returns
292         * CDM-3: "Charge Description Short" - creates it if necessary
293         */
294        public ST getCdm3_ChargeDescriptionShort() { 
295            ST ret = null;
296            try {
297                Type t = this.getField(3, 0);
298                ret = (ST)t;
299            } catch (ClassCastException cce) {
300                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
301                throw new RuntimeException(cce);
302            } catch (HL7Exception he) {
303                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
304                throw new RuntimeException(he);
305            }
306            return ret;
307        }
308    
309    
310    
311        /**
312         * Returns
313         * CDM-4: "Charge Description Long" - creates it if necessary
314         */
315        public ST getChargeDescriptionLong() { 
316            ST ret = null;
317            try {
318                Type t = this.getField(4, 0);
319                ret = (ST)t;
320            } catch (ClassCastException cce) {
321                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
322                throw new RuntimeException(cce);
323            } catch (HL7Exception he) {
324                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
325                throw new RuntimeException(he);
326            }
327            return ret;
328        }
329    
330    
331        /**
332         * Returns
333         * CDM-4: "Charge Description Long" - creates it if necessary
334         */
335        public ST getCdm4_ChargeDescriptionLong() { 
336            ST ret = null;
337            try {
338                Type t = this.getField(4, 0);
339                ret = (ST)t;
340            } catch (ClassCastException cce) {
341                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
342                throw new RuntimeException(cce);
343            } catch (HL7Exception he) {
344                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
345                throw new RuntimeException(he);
346            }
347            return ret;
348        }
349    
350    
351    
352        /**
353         * Returns
354         * CDM-5: "Description Override Indicator" - creates it if necessary
355         */
356        public IS getDescriptionOverrideIndicator() { 
357            IS ret = null;
358            try {
359                Type t = this.getField(5, 0);
360                ret = (IS)t;
361            } catch (ClassCastException cce) {
362                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
363                throw new RuntimeException(cce);
364            } catch (HL7Exception he) {
365                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
366                throw new RuntimeException(he);
367            }
368            return ret;
369        }
370    
371    
372        /**
373         * Returns
374         * CDM-5: "Description Override Indicator" - creates it if necessary
375         */
376        public IS getCdm5_DescriptionOverrideIndicator() { 
377            IS ret = null;
378            try {
379                Type t = this.getField(5, 0);
380                ret = (IS)t;
381            } catch (ClassCastException cce) {
382                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
383                throw new RuntimeException(cce);
384            } catch (HL7Exception he) {
385                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
386                throw new RuntimeException(he);
387            }
388            return ret;
389        }
390    
391    
392        /**
393         * Returns all repetitions of Exploding Charges (CDM-6).
394         */
395        public CE[] getExplodingCharges() {
396            CE[] ret = null;
397            try {
398                Type[] t = this.getField(6);  
399                ret = new CE[t.length];
400                for (int i = 0; i < ret.length; i++) {
401                    ret[i] = (CE)t[i];
402                }
403            } catch (ClassCastException cce) {
404                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
405                throw new RuntimeException(cce);
406            } catch (HL7Exception he) {
407                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
408                throw new RuntimeException(he);
409            }
410            return ret;
411        }
412    
413    
414        /**
415         * Returns a count of the current number of repetitions of Exploding Charges (CDM-6).
416         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
417         * it will return zero.
418         */
419        public int getExplodingChargesReps() {
420            CE[] ret = null;
421            try {
422                Type[] t = this.getField(6);
423                return t.length;  
424            } catch (ClassCastException cce) {
425                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
426                throw new RuntimeException(cce);
427            } catch (HL7Exception he) {
428                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
429                throw new RuntimeException(he);
430            }
431        }
432    
433    
434        /**
435         * Returns a specific repetition of
436         * CDM-6: "Exploding Charges" - creates it if necessary
437         *
438         * @param rep The repetition index (0-indexed)
439         */
440        public CE getExplodingCharges(int rep) { 
441            CE ret = null;
442            try {
443                Type t = this.getField(6, rep);
444                ret = (CE)t;
445            } catch (ClassCastException cce) {
446                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
447                throw new RuntimeException(cce);
448            } catch (HL7Exception he) {
449                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
450                throw new RuntimeException(he);
451            }
452            return ret;
453        }
454    
455        /**
456         * Returns a specific repetition of
457         * CDM-6: "Exploding Charges" - creates it if necessary
458         *
459         * @param rep The repetition index (0-indexed)
460         */
461        public CE getCdm6_ExplodingCharges(int rep) { 
462            CE ret = null;
463            try {
464                Type t = this.getField(6, rep);
465                ret = (CE)t;
466            } catch (ClassCastException cce) {
467                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
468                throw new RuntimeException(cce);
469            } catch (HL7Exception he) {
470                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
471                throw new RuntimeException(he);
472            }
473            return ret;
474        }
475    
476    
477        /**
478         * Returns a count of the current number of repetitions of Exploding Charges (CDM-6).
479         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
480         * it will return zero.
481         */
482        public int getCdm6_ExplodingChargesReps() {
483            CE[] ret = null;
484            try {
485                Type[] t = this.getField(6);
486                return t.length;  
487            } catch (ClassCastException cce) {
488                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
489                throw new RuntimeException(cce);
490            } catch (HL7Exception he) {
491                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
492                throw new RuntimeException(he);
493            }
494        }
495    
496    
497    
498        /**
499         * Inserts a repetition of
500         * CDM-6: "Exploding Charges" at a specific index
501         *
502         * @param rep The repetition index (0-indexed)
503         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
504         */
505        public CE insertExplodingCharges(int rep) throws HL7Exception { 
506            return (CE) super.insertRepetition(6, rep);
507        }
508    
509    
510    
511        /**
512         * Inserts a repetition of
513         * CDM-6: "Exploding Charges" at a specific index
514         *
515         * @param rep The repetition index (0-indexed)
516         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
517         */
518        public CE insertCdm6_ExplodingCharges(int rep) throws HL7Exception { 
519            return (CE) super.insertRepetition(6, rep);
520        }
521    
522    
523        /**
524         * Removes a repetition of
525         * CDM-6: "Exploding Charges" at a specific index
526         *
527         * @param rep The repetition index (0-indexed)
528         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
529         */
530        public CE removeExplodingCharges(int rep) throws HL7Exception { 
531            return (CE) super.removeRepetition(6, rep);
532        }
533    
534    
535        /**
536         * Removes a repetition of
537         * CDM-6: "Exploding Charges" at a specific index
538         *
539         * @param rep The repetition index (0-indexed)
540         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
541         */
542        public CE removeCdm6_ExplodingCharges(int rep) throws HL7Exception { 
543            return (CE) super.removeRepetition(6, rep);
544        }
545    
546    
547    
548        /**
549         * Returns all repetitions of Procedure Code (CDM-7).
550         */
551        public CE[] getProcedureCode() {
552            CE[] ret = null;
553            try {
554                Type[] t = this.getField(7);  
555                ret = new CE[t.length];
556                for (int i = 0; i < ret.length; i++) {
557                    ret[i] = (CE)t[i];
558                }
559            } catch (ClassCastException cce) {
560                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
561                throw new RuntimeException(cce);
562            } catch (HL7Exception he) {
563                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
564                throw new RuntimeException(he);
565            }
566            return ret;
567        }
568    
569    
570        /**
571         * Returns a count of the current number of repetitions of Procedure Code (CDM-7).
572         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
573         * it will return zero.
574         */
575        public int getProcedureCodeReps() {
576            CE[] ret = null;
577            try {
578                Type[] t = this.getField(7);
579                return t.length;  
580            } catch (ClassCastException cce) {
581                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
582                throw new RuntimeException(cce);
583            } catch (HL7Exception he) {
584                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
585                throw new RuntimeException(he);
586            }
587        }
588    
589    
590        /**
591         * Returns a specific repetition of
592         * CDM-7: "Procedure Code" - creates it if necessary
593         *
594         * @param rep The repetition index (0-indexed)
595         */
596        public CE getProcedureCode(int rep) { 
597            CE ret = null;
598            try {
599                Type t = this.getField(7, rep);
600                ret = (CE)t;
601            } catch (ClassCastException cce) {
602                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
603                throw new RuntimeException(cce);
604            } catch (HL7Exception he) {
605                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
606                throw new RuntimeException(he);
607            }
608            return ret;
609        }
610    
611        /**
612         * Returns a specific repetition of
613         * CDM-7: "Procedure Code" - creates it if necessary
614         *
615         * @param rep The repetition index (0-indexed)
616         */
617        public CE getCdm7_ProcedureCode(int rep) { 
618            CE ret = null;
619            try {
620                Type t = this.getField(7, rep);
621                ret = (CE)t;
622            } catch (ClassCastException cce) {
623                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
624                throw new RuntimeException(cce);
625            } catch (HL7Exception he) {
626                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
627                throw new RuntimeException(he);
628            }
629            return ret;
630        }
631    
632    
633        /**
634         * Returns a count of the current number of repetitions of Procedure Code (CDM-7).
635         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
636         * it will return zero.
637         */
638        public int getCdm7_ProcedureCodeReps() {
639            CE[] ret = null;
640            try {
641                Type[] t = this.getField(7);
642                return t.length;  
643            } catch (ClassCastException cce) {
644                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
645                throw new RuntimeException(cce);
646            } catch (HL7Exception he) {
647                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
648                throw new RuntimeException(he);
649            }
650        }
651    
652    
653    
654        /**
655         * Inserts a repetition of
656         * CDM-7: "Procedure Code" at a specific index
657         *
658         * @param rep The repetition index (0-indexed)
659         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
660         */
661        public CE insertProcedureCode(int rep) throws HL7Exception { 
662            return (CE) super.insertRepetition(7, rep);
663        }
664    
665    
666    
667        /**
668         * Inserts a repetition of
669         * CDM-7: "Procedure Code" at a specific index
670         *
671         * @param rep The repetition index (0-indexed)
672         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
673         */
674        public CE insertCdm7_ProcedureCode(int rep) throws HL7Exception { 
675            return (CE) super.insertRepetition(7, rep);
676        }
677    
678    
679        /**
680         * Removes a repetition of
681         * CDM-7: "Procedure Code" at a specific index
682         *
683         * @param rep The repetition index (0-indexed)
684         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
685         */
686        public CE removeProcedureCode(int rep) throws HL7Exception { 
687            return (CE) super.removeRepetition(7, rep);
688        }
689    
690    
691        /**
692         * Removes a repetition of
693         * CDM-7: "Procedure Code" at a specific index
694         *
695         * @param rep The repetition index (0-indexed)
696         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
697         */
698        public CE removeCdm7_ProcedureCode(int rep) throws HL7Exception { 
699            return (CE) super.removeRepetition(7, rep);
700        }
701    
702    
703    
704    
705        /**
706         * Returns
707         * CDM-8: "Active/Inactive Flag" - creates it if necessary
708         */
709        public ID getActiveInactiveFlag() { 
710            ID ret = null;
711            try {
712                Type t = this.getField(8, 0);
713                ret = (ID)t;
714            } catch (ClassCastException cce) {
715                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
716                throw new RuntimeException(cce);
717            } catch (HL7Exception he) {
718                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
719                throw new RuntimeException(he);
720            }
721            return ret;
722        }
723    
724    
725        /**
726         * Returns
727         * CDM-8: "Active/Inactive Flag" - creates it if necessary
728         */
729        public ID getCdm8_ActiveInactiveFlag() { 
730            ID ret = null;
731            try {
732                Type t = this.getField(8, 0);
733                ret = (ID)t;
734            } catch (ClassCastException cce) {
735                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
736                throw new RuntimeException(cce);
737            } catch (HL7Exception he) {
738                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
739                throw new RuntimeException(he);
740            }
741            return ret;
742        }
743    
744    
745        /**
746         * Returns all repetitions of Inventory Number (CDM-9).
747         */
748        public CE[] getInventoryNumber() {
749            CE[] ret = null;
750            try {
751                Type[] t = this.getField(9);  
752                ret = new CE[t.length];
753                for (int i = 0; i < ret.length; i++) {
754                    ret[i] = (CE)t[i];
755                }
756            } catch (ClassCastException cce) {
757                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
758                throw new RuntimeException(cce);
759            } catch (HL7Exception he) {
760                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
761                throw new RuntimeException(he);
762            }
763            return ret;
764        }
765    
766    
767        /**
768         * Returns a count of the current number of repetitions of Inventory Number (CDM-9).
769         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
770         * it will return zero.
771         */
772        public int getInventoryNumberReps() {
773            CE[] ret = null;
774            try {
775                Type[] t = this.getField(9);
776                return t.length;  
777            } catch (ClassCastException cce) {
778                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
779                throw new RuntimeException(cce);
780            } catch (HL7Exception he) {
781                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
782                throw new RuntimeException(he);
783            }
784        }
785    
786    
787        /**
788         * Returns a specific repetition of
789         * CDM-9: "Inventory Number" - creates it if necessary
790         *
791         * @param rep The repetition index (0-indexed)
792         */
793        public CE getInventoryNumber(int rep) { 
794            CE ret = null;
795            try {
796                Type t = this.getField(9, rep);
797                ret = (CE)t;
798            } catch (ClassCastException cce) {
799                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
800                throw new RuntimeException(cce);
801            } catch (HL7Exception he) {
802                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
803                throw new RuntimeException(he);
804            }
805            return ret;
806        }
807    
808        /**
809         * Returns a specific repetition of
810         * CDM-9: "Inventory Number" - creates it if necessary
811         *
812         * @param rep The repetition index (0-indexed)
813         */
814        public CE getCdm9_InventoryNumber(int rep) { 
815            CE ret = null;
816            try {
817                Type t = this.getField(9, rep);
818                ret = (CE)t;
819            } catch (ClassCastException cce) {
820                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
821                throw new RuntimeException(cce);
822            } catch (HL7Exception he) {
823                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
824                throw new RuntimeException(he);
825            }
826            return ret;
827        }
828    
829    
830        /**
831         * Returns a count of the current number of repetitions of Inventory Number (CDM-9).
832         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
833         * it will return zero.
834         */
835        public int getCdm9_InventoryNumberReps() {
836            CE[] ret = null;
837            try {
838                Type[] t = this.getField(9);
839                return t.length;  
840            } catch (ClassCastException cce) {
841                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
842                throw new RuntimeException(cce);
843            } catch (HL7Exception he) {
844                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
845                throw new RuntimeException(he);
846            }
847        }
848    
849    
850    
851        /**
852         * Inserts a repetition of
853         * CDM-9: "Inventory Number" at a specific index
854         *
855         * @param rep The repetition index (0-indexed)
856         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
857         */
858        public CE insertInventoryNumber(int rep) throws HL7Exception { 
859            return (CE) super.insertRepetition(9, rep);
860        }
861    
862    
863    
864        /**
865         * Inserts a repetition of
866         * CDM-9: "Inventory Number" at a specific index
867         *
868         * @param rep The repetition index (0-indexed)
869         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
870         */
871        public CE insertCdm9_InventoryNumber(int rep) throws HL7Exception { 
872            return (CE) super.insertRepetition(9, rep);
873        }
874    
875    
876        /**
877         * Removes a repetition of
878         * CDM-9: "Inventory Number" at a specific index
879         *
880         * @param rep The repetition index (0-indexed)
881         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
882         */
883        public CE removeInventoryNumber(int rep) throws HL7Exception { 
884            return (CE) super.removeRepetition(9, rep);
885        }
886    
887    
888        /**
889         * Removes a repetition of
890         * CDM-9: "Inventory Number" at a specific index
891         *
892         * @param rep The repetition index (0-indexed)
893         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
894         */
895        public CE removeCdm9_InventoryNumber(int rep) throws HL7Exception { 
896            return (CE) super.removeRepetition(9, rep);
897        }
898    
899    
900    
901    
902        /**
903         * Returns
904         * CDM-10: "Resource Load" - creates it if necessary
905         */
906        public NM getResourceLoad() { 
907            NM ret = null;
908            try {
909                Type t = this.getField(10, 0);
910                ret = (NM)t;
911            } catch (ClassCastException cce) {
912                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
913                throw new RuntimeException(cce);
914            } catch (HL7Exception he) {
915                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
916                throw new RuntimeException(he);
917            }
918            return ret;
919        }
920    
921    
922        /**
923         * Returns
924         * CDM-10: "Resource Load" - creates it if necessary
925         */
926        public NM getCdm10_ResourceLoad() { 
927            NM ret = null;
928            try {
929                Type t = this.getField(10, 0);
930                ret = (NM)t;
931            } catch (ClassCastException cce) {
932                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
933                throw new RuntimeException(cce);
934            } catch (HL7Exception he) {
935                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
936                throw new RuntimeException(he);
937            }
938            return ret;
939        }
940    
941    
942        /**
943         * Returns all repetitions of Contract Number (CDM-11).
944         */
945        public CK[] getContractNumber() {
946            CK[] ret = null;
947            try {
948                Type[] t = this.getField(11);  
949                ret = new CK[t.length];
950                for (int i = 0; i < ret.length; i++) {
951                    ret[i] = (CK)t[i];
952                }
953            } catch (ClassCastException cce) {
954                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
955                throw new RuntimeException(cce);
956            } catch (HL7Exception he) {
957                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
958                throw new RuntimeException(he);
959            }
960            return ret;
961        }
962    
963    
964        /**
965         * Returns a count of the current number of repetitions of Contract Number (CDM-11).
966         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
967         * it will return zero.
968         */
969        public int getContractNumberReps() {
970            CK[] ret = null;
971            try {
972                Type[] t = this.getField(11);
973                return t.length;  
974            } catch (ClassCastException cce) {
975                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
976                throw new RuntimeException(cce);
977            } catch (HL7Exception he) {
978                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
979                throw new RuntimeException(he);
980            }
981        }
982    
983    
984        /**
985         * Returns a specific repetition of
986         * CDM-11: "Contract Number" - creates it if necessary
987         *
988         * @param rep The repetition index (0-indexed)
989         */
990        public CK getContractNumber(int rep) { 
991            CK ret = null;
992            try {
993                Type t = this.getField(11, rep);
994                ret = (CK)t;
995            } catch (ClassCastException cce) {
996                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
997                throw new RuntimeException(cce);
998            } catch (HL7Exception he) {
999                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1000                throw new RuntimeException(he);
1001            }
1002            return ret;
1003        }
1004    
1005        /**
1006         * Returns a specific repetition of
1007         * CDM-11: "Contract Number" - creates it if necessary
1008         *
1009         * @param rep The repetition index (0-indexed)
1010         */
1011        public CK getCdm11_ContractNumber(int rep) { 
1012            CK ret = null;
1013            try {
1014                Type t = this.getField(11, rep);
1015                ret = (CK)t;
1016            } catch (ClassCastException cce) {
1017                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1018                throw new RuntimeException(cce);
1019            } catch (HL7Exception he) {
1020                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1021                throw new RuntimeException(he);
1022            }
1023            return ret;
1024        }
1025    
1026    
1027        /**
1028         * Returns a count of the current number of repetitions of Contract Number (CDM-11).
1029         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1030         * it will return zero.
1031         */
1032        public int getCdm11_ContractNumberReps() {
1033            CK[] ret = null;
1034            try {
1035                Type[] t = this.getField(11);
1036                return t.length;  
1037            } catch (ClassCastException cce) {
1038                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1039                throw new RuntimeException(cce);
1040            } catch (HL7Exception he) {
1041                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1042                throw new RuntimeException(he);
1043            }
1044        }
1045    
1046    
1047    
1048        /**
1049         * Inserts a repetition of
1050         * CDM-11: "Contract Number" at a specific index
1051         *
1052         * @param rep The repetition index (0-indexed)
1053         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1054         */
1055        public CK insertContractNumber(int rep) throws HL7Exception { 
1056            return (CK) super.insertRepetition(11, rep);
1057        }
1058    
1059    
1060    
1061        /**
1062         * Inserts a repetition of
1063         * CDM-11: "Contract Number" at a specific index
1064         *
1065         * @param rep The repetition index (0-indexed)
1066         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1067         */
1068        public CK insertCdm11_ContractNumber(int rep) throws HL7Exception { 
1069            return (CK) super.insertRepetition(11, rep);
1070        }
1071    
1072    
1073        /**
1074         * Removes a repetition of
1075         * CDM-11: "Contract Number" at a specific index
1076         *
1077         * @param rep The repetition index (0-indexed)
1078         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1079         */
1080        public CK removeContractNumber(int rep) throws HL7Exception { 
1081            return (CK) super.removeRepetition(11, rep);
1082        }
1083    
1084    
1085        /**
1086         * Removes a repetition of
1087         * CDM-11: "Contract Number" at a specific index
1088         *
1089         * @param rep The repetition index (0-indexed)
1090         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1091         */
1092        public CK removeCdm11_ContractNumber(int rep) throws HL7Exception { 
1093            return (CK) super.removeRepetition(11, rep);
1094        }
1095    
1096    
1097    
1098        /**
1099         * Returns all repetitions of Contract Organization (CDM-12).
1100         */
1101        public XON[] getContractOrganization() {
1102            XON[] ret = null;
1103            try {
1104                Type[] t = this.getField(12);  
1105                ret = new XON[t.length];
1106                for (int i = 0; i < ret.length; i++) {
1107                    ret[i] = (XON)t[i];
1108                }
1109            } catch (ClassCastException cce) {
1110                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1111                throw new RuntimeException(cce);
1112            } catch (HL7Exception he) {
1113                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1114                throw new RuntimeException(he);
1115            }
1116            return ret;
1117        }
1118    
1119    
1120        /**
1121         * Returns a count of the current number of repetitions of Contract Organization (CDM-12).
1122         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1123         * it will return zero.
1124         */
1125        public int getContractOrganizationReps() {
1126            XON[] ret = null;
1127            try {
1128                Type[] t = this.getField(12);
1129                return t.length;  
1130            } catch (ClassCastException cce) {
1131                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1132                throw new RuntimeException(cce);
1133            } catch (HL7Exception he) {
1134                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1135                throw new RuntimeException(he);
1136            }
1137        }
1138    
1139    
1140        /**
1141         * Returns a specific repetition of
1142         * CDM-12: "Contract Organization" - creates it if necessary
1143         *
1144         * @param rep The repetition index (0-indexed)
1145         */
1146        public XON getContractOrganization(int rep) { 
1147            XON ret = null;
1148            try {
1149                Type t = this.getField(12, rep);
1150                ret = (XON)t;
1151            } catch (ClassCastException cce) {
1152                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1153                throw new RuntimeException(cce);
1154            } catch (HL7Exception he) {
1155                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1156                throw new RuntimeException(he);
1157            }
1158            return ret;
1159        }
1160    
1161        /**
1162         * Returns a specific repetition of
1163         * CDM-12: "Contract Organization" - creates it if necessary
1164         *
1165         * @param rep The repetition index (0-indexed)
1166         */
1167        public XON getCdm12_ContractOrganization(int rep) { 
1168            XON ret = null;
1169            try {
1170                Type t = this.getField(12, rep);
1171                ret = (XON)t;
1172            } catch (ClassCastException cce) {
1173                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1174                throw new RuntimeException(cce);
1175            } catch (HL7Exception he) {
1176                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1177                throw new RuntimeException(he);
1178            }
1179            return ret;
1180        }
1181    
1182    
1183        /**
1184         * Returns a count of the current number of repetitions of Contract Organization (CDM-12).
1185         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1186         * it will return zero.
1187         */
1188        public int getCdm12_ContractOrganizationReps() {
1189            XON[] ret = null;
1190            try {
1191                Type[] t = this.getField(12);
1192                return t.length;  
1193            } catch (ClassCastException cce) {
1194                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1195                throw new RuntimeException(cce);
1196            } catch (HL7Exception he) {
1197                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1198                throw new RuntimeException(he);
1199            }
1200        }
1201    
1202    
1203    
1204        /**
1205         * Inserts a repetition of
1206         * CDM-12: "Contract Organization" at a specific index
1207         *
1208         * @param rep The repetition index (0-indexed)
1209         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1210         */
1211        public XON insertContractOrganization(int rep) throws HL7Exception { 
1212            return (XON) super.insertRepetition(12, rep);
1213        }
1214    
1215    
1216    
1217        /**
1218         * Inserts a repetition of
1219         * CDM-12: "Contract Organization" at a specific index
1220         *
1221         * @param rep The repetition index (0-indexed)
1222         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1223         */
1224        public XON insertCdm12_ContractOrganization(int rep) throws HL7Exception { 
1225            return (XON) super.insertRepetition(12, rep);
1226        }
1227    
1228    
1229        /**
1230         * Removes a repetition of
1231         * CDM-12: "Contract Organization" at a specific index
1232         *
1233         * @param rep The repetition index (0-indexed)
1234         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1235         */
1236        public XON removeContractOrganization(int rep) throws HL7Exception { 
1237            return (XON) super.removeRepetition(12, rep);
1238        }
1239    
1240    
1241        /**
1242         * Removes a repetition of
1243         * CDM-12: "Contract Organization" at a specific index
1244         *
1245         * @param rep The repetition index (0-indexed)
1246         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1247         */
1248        public XON removeCdm12_ContractOrganization(int rep) throws HL7Exception { 
1249            return (XON) super.removeRepetition(12, rep);
1250        }
1251    
1252    
1253    
1254    
1255        /**
1256         * Returns
1257         * CDM-13: "Room Fee Indicator" - creates it if necessary
1258         */
1259        public ID getRoomFeeIndicator() { 
1260            ID ret = null;
1261            try {
1262                Type t = this.getField(13, 0);
1263                ret = (ID)t;
1264            } catch (ClassCastException cce) {
1265                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1266                throw new RuntimeException(cce);
1267            } catch (HL7Exception he) {
1268                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1269                throw new RuntimeException(he);
1270            }
1271            return ret;
1272        }
1273    
1274    
1275        /**
1276         * Returns
1277         * CDM-13: "Room Fee Indicator" - creates it if necessary
1278         */
1279        public ID getCdm13_RoomFeeIndicator() { 
1280            ID ret = null;
1281            try {
1282                Type t = this.getField(13, 0);
1283                ret = (ID)t;
1284            } catch (ClassCastException cce) {
1285                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1286                throw new RuntimeException(cce);
1287            } catch (HL7Exception he) {
1288                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1289                throw new RuntimeException(he);
1290            }
1291            return ret;
1292        }
1293    
1294    
1295    
1296    
1297    
1298        /** {@inheritDoc} */   
1299        protected Type createNewTypeWithoutReflection(int field) {
1300           switch (field) {
1301              case 0: return new CE(getMessage());
1302              case 1: return new CE(getMessage());
1303              case 2: return new ST(getMessage());
1304              case 3: return new ST(getMessage());
1305              case 4: return new IS(getMessage(), new Integer( 268 ));
1306              case 5: return new CE(getMessage());
1307              case 6: return new CE(getMessage());
1308              case 7: return new ID(getMessage(), new Integer( 183 ));
1309              case 8: return new CE(getMessage());
1310              case 9: return new NM(getMessage());
1311              case 10: return new CK(getMessage());
1312              case 11: return new XON(getMessage());
1313              case 12: return new ID(getMessage(), new Integer( 136 ));
1314              default: return null;
1315           }
1316       }
1317    
1318    
1319    }
1320