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 STF message segment (Staff Identification). 
024     * This segment has the following fields:</p>
025     * <ul>
026         * <li>STF-1: Primary Key Value - STF (CE) <b>optional </b>
027         * <li>STF-2: Staff ID Code (CX) <b>optional repeating</b>
028         * <li>STF-3: Staff Name (XPN) <b>optional repeating</b>
029         * <li>STF-4: Staff Type (IS) <b>optional repeating</b>
030         * <li>STF-5: Administrative Sex (IS) <b>optional </b>
031         * <li>STF-6: Date/Time Of Birth (TS) <b>optional </b>
032         * <li>STF-7: Active/Inactive Flag (ID) <b>optional </b>
033         * <li>STF-8: Department (CE) <b>optional repeating</b>
034         * <li>STF-9: Hospital Service (CE) <b>optional repeating</b>
035         * <li>STF-10: Phone (XTN) <b>optional repeating</b>
036         * <li>STF-11: Office/Home Address (XAD) <b>optional repeating</b>
037         * <li>STF-12: Institution Activation Date (DIN) <b>optional repeating</b>
038         * <li>STF-13: Institution Inactivation Date (DIN) <b>optional repeating</b>
039         * <li>STF-14: Backup Person ID (CE) <b>optional repeating</b>
040         * <li>STF-15: E-Mail Address (ST) <b>optional repeating</b>
041         * <li>STF-16: Preferred Method of Contact (CE) <b>optional </b>
042         * <li>STF-17: Marital Status (CE) <b>optional </b>
043         * <li>STF-18: Job Title (ST) <b>optional </b>
044         * <li>STF-19: Job Code/Class (JCC) <b>optional </b>
045         * <li>STF-20: Employment Status Code (CE) <b>optional </b>
046         * <li>STF-21: Additional Insured on  Auto (ID) <b>optional </b>
047         * <li>STF-22: Driver's License Number - Staff (DLN) <b>optional </b>
048         * <li>STF-23: Copy  Auto Ins (ID) <b>optional </b>
049         * <li>STF-24: Auto Ins. Expires (DT) <b>optional </b>
050         * <li>STF-25: Date Last DMV Review (DT) <b>optional </b>
051         * <li>STF-26: Date Next DMV Review (DT) <b>optional </b>
052         * <li>STF-27: Race (CE) <b>optional </b>
053         * <li>STF-28: Ethnic Group (CE) <b>optional </b>
054         * <li>STF-29: Re-activation Approval Indicator (ID) <b>optional </b>
055     * </ul>
056     */
057    public class STF extends AbstractSegment {
058    
059        /** 
060         * Creates a new STF segment
061         */
062        public STF(Group parent, ModelClassFactory factory) {
063           super(parent, factory);
064           init(factory);
065        }
066    
067        private void init(ModelClassFactory factory) {
068           try {
069                                      this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(9999) }, "Primary Key Value - STF");
070                                      this.add(CX.class, false, 0, 60, new Object[]{ getMessage(), new Integer(0) }, "Staff ID Code");
071                                      this.add(XPN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Staff Name");
072                                      this.add(IS.class, false, 0, 2, new Object[]{ getMessage() }, "Staff Type");
073                                      this.add(IS.class, false, 1, 1, new Object[]{ getMessage() }, "Administrative Sex");
074                                      this.add(TS.class, false, 1, 26, new Object[]{ getMessage(), new Integer(0) }, "Date/Time Of Birth");
075                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Active/Inactive Flag");
076                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(184) }, "Department");
077                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(69) }, "Hospital Service");
078                                      this.add(XTN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Phone");
079                                      this.add(XAD.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Office/Home Address");
080                                      this.add(DIN.class, false, 0, 26, new Object[]{ getMessage(), new Integer(0) }, "Institution Activation Date");
081                                      this.add(DIN.class, false, 0, 26, new Object[]{ getMessage(), new Integer(0) }, "Institution Inactivation Date");
082                                      this.add(CE.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Backup Person ID");
083                                      this.add(ST.class, false, 0, 40, new Object[]{ getMessage(), new Integer(0) }, "E-Mail Address");
084                                      this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(185) }, "Preferred Method of Contact");
085                                      this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(2) }, "Marital Status");
086                                      this.add(ST.class, false, 1, 20, new Object[]{ getMessage(), new Integer(0) }, "Job Title");
087                                      this.add(JCC.class, false, 1, 20, new Object[]{ getMessage(), new Integer(327) }, "Job Code/Class");
088                                      this.add(CE.class, false, 1, 2, new Object[]{ getMessage(), new Integer(66) }, "Employment Status Code");
089                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Additional Insured on  Auto");
090                                      this.add(DLN.class, false, 1, 25, new Object[]{ getMessage(), new Integer(0) }, "Driver's License Number - Staff");
091                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Copy  Auto Ins");
092                                      this.add(DT.class, false, 1, 8, new Object[]{ getMessage(), new Integer(0) }, "Auto Ins. Expires");
093                                      this.add(DT.class, false, 1, 8, new Object[]{ getMessage(), new Integer(0) }, "Date Last DMV Review");
094                                      this.add(DT.class, false, 1, 8, new Object[]{ getMessage(), new Integer(0) }, "Date Next DMV Review");
095                                      this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(5) }, "Race");
096                                      this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(189) }, "Ethnic Group");
097                                      this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Re-activation Approval Indicator");
098           } catch(HL7Exception e) {
099              HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected error creating STF - this is probably a bug in the source code generator.", e);
100           }
101        }
102    
103    
104    
105        /**
106         * Returns
107         * STF-1: "Primary Key Value - STF" - creates it if necessary
108         */
109        public CE getPrimaryKeyValueSTF() { 
110            CE ret = null;
111            try {
112                Type t = this.getField(1, 0);
113                ret = (CE)t;
114            } catch (ClassCastException cce) {
115                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
116                throw new RuntimeException(cce);
117            } catch (HL7Exception he) {
118                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
119                throw new RuntimeException(he);
120            }
121            return ret;
122        }
123    
124    
125        /**
126         * Returns
127         * STF-1: "Primary Key Value - STF" - creates it if necessary
128         */
129        public CE getStf1_PrimaryKeyValueSTF() { 
130            CE ret = null;
131            try {
132                Type t = this.getField(1, 0);
133                ret = (CE)t;
134            } catch (ClassCastException cce) {
135                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
136                throw new RuntimeException(cce);
137            } catch (HL7Exception he) {
138                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
139                throw new RuntimeException(he);
140            }
141            return ret;
142        }
143    
144    
145        /**
146         * Returns all repetitions of Staff ID Code (STF-2).
147         */
148        public CX[] getStaffIDCode() {
149            CX[] ret = null;
150            try {
151                Type[] t = this.getField(2);  
152                ret = new CX[t.length];
153                for (int i = 0; i < ret.length; i++) {
154                    ret[i] = (CX)t[i];
155                }
156            } catch (ClassCastException cce) {
157                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
158                throw new RuntimeException(cce);
159            } catch (HL7Exception he) {
160                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
161                throw new RuntimeException(he);
162            }
163            return ret;
164        }
165    
166    
167        /**
168         * Returns a count of the current number of repetitions of Staff ID Code (STF-2).
169         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
170         * it will return zero.
171         */
172        public int getStaffIDCodeReps() {
173            CX[] ret = null;
174            try {
175                Type[] t = this.getField(2);
176                return t.length;  
177            } catch (ClassCastException cce) {
178                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
179                throw new RuntimeException(cce);
180            } catch (HL7Exception he) {
181                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
182                throw new RuntimeException(he);
183            }
184        }
185    
186    
187        /**
188         * Returns a specific repetition of
189         * STF-2: "Staff ID Code" - creates it if necessary
190         *
191         * @param rep The repetition index (0-indexed)
192         */
193        public CX getStaffIDCode(int rep) { 
194            CX ret = null;
195            try {
196                Type t = this.getField(2, rep);
197                ret = (CX)t;
198            } catch (ClassCastException cce) {
199                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
200                throw new RuntimeException(cce);
201            } catch (HL7Exception he) {
202                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
203                throw new RuntimeException(he);
204            }
205            return ret;
206        }
207    
208        /**
209         * Returns a specific repetition of
210         * STF-2: "Staff ID Code" - creates it if necessary
211         *
212         * @param rep The repetition index (0-indexed)
213         */
214        public CX getStf2_StaffIDCode(int rep) { 
215            CX ret = null;
216            try {
217                Type t = this.getField(2, rep);
218                ret = (CX)t;
219            } catch (ClassCastException cce) {
220                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
221                throw new RuntimeException(cce);
222            } catch (HL7Exception he) {
223                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
224                throw new RuntimeException(he);
225            }
226            return ret;
227        }
228    
229    
230        /**
231         * Returns a count of the current number of repetitions of Staff ID Code (STF-2).
232         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
233         * it will return zero.
234         */
235        public int getStf2_StaffIDCodeReps() {
236            CX[] ret = null;
237            try {
238                Type[] t = this.getField(2);
239                return t.length;  
240            } catch (ClassCastException cce) {
241                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
242                throw new RuntimeException(cce);
243            } catch (HL7Exception he) {
244                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
245                throw new RuntimeException(he);
246            }
247        }
248    
249    
250    
251        /**
252         * Inserts a repetition of
253         * STF-2: "Staff ID Code" at a specific index
254         *
255         * @param rep The repetition index (0-indexed)
256         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
257         */
258        public CX insertStaffIDCode(int rep) throws HL7Exception { 
259            return (CX) super.insertRepetition(2, rep);
260        }
261    
262    
263    
264        /**
265         * Inserts a repetition of
266         * STF-2: "Staff ID Code" at a specific index
267         *
268         * @param rep The repetition index (0-indexed)
269         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
270         */
271        public CX insertStf2_StaffIDCode(int rep) throws HL7Exception { 
272            return (CX) super.insertRepetition(2, rep);
273        }
274    
275    
276        /**
277         * Removes a repetition of
278         * STF-2: "Staff ID Code" at a specific index
279         *
280         * @param rep The repetition index (0-indexed)
281         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
282         */
283        public CX removeStaffIDCode(int rep) throws HL7Exception { 
284            return (CX) super.removeRepetition(2, rep);
285        }
286    
287    
288        /**
289         * Removes a repetition of
290         * STF-2: "Staff ID Code" at a specific index
291         *
292         * @param rep The repetition index (0-indexed)
293         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
294         */
295        public CX removeStf2_StaffIDCode(int rep) throws HL7Exception { 
296            return (CX) super.removeRepetition(2, rep);
297        }
298    
299    
300    
301        /**
302         * Returns all repetitions of Staff Name (STF-3).
303         */
304        public XPN[] getStaffName() {
305            XPN[] ret = null;
306            try {
307                Type[] t = this.getField(3);  
308                ret = new XPN[t.length];
309                for (int i = 0; i < ret.length; i++) {
310                    ret[i] = (XPN)t[i];
311                }
312            } catch (ClassCastException cce) {
313                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
314                throw new RuntimeException(cce);
315            } catch (HL7Exception he) {
316                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
317                throw new RuntimeException(he);
318            }
319            return ret;
320        }
321    
322    
323        /**
324         * Returns a count of the current number of repetitions of Staff Name (STF-3).
325         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
326         * it will return zero.
327         */
328        public int getStaffNameReps() {
329            XPN[] ret = null;
330            try {
331                Type[] t = this.getField(3);
332                return t.length;  
333            } catch (ClassCastException cce) {
334                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
335                throw new RuntimeException(cce);
336            } catch (HL7Exception he) {
337                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
338                throw new RuntimeException(he);
339            }
340        }
341    
342    
343        /**
344         * Returns a specific repetition of
345         * STF-3: "Staff Name" - creates it if necessary
346         *
347         * @param rep The repetition index (0-indexed)
348         */
349        public XPN getStaffName(int rep) { 
350            XPN ret = null;
351            try {
352                Type t = this.getField(3, rep);
353                ret = (XPN)t;
354            } catch (ClassCastException cce) {
355                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
356                throw new RuntimeException(cce);
357            } catch (HL7Exception he) {
358                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
359                throw new RuntimeException(he);
360            }
361            return ret;
362        }
363    
364        /**
365         * Returns a specific repetition of
366         * STF-3: "Staff Name" - creates it if necessary
367         *
368         * @param rep The repetition index (0-indexed)
369         */
370        public XPN getStf3_StaffName(int rep) { 
371            XPN ret = null;
372            try {
373                Type t = this.getField(3, rep);
374                ret = (XPN)t;
375            } catch (ClassCastException cce) {
376                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
377                throw new RuntimeException(cce);
378            } catch (HL7Exception he) {
379                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
380                throw new RuntimeException(he);
381            }
382            return ret;
383        }
384    
385    
386        /**
387         * Returns a count of the current number of repetitions of Staff Name (STF-3).
388         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
389         * it will return zero.
390         */
391        public int getStf3_StaffNameReps() {
392            XPN[] ret = null;
393            try {
394                Type[] t = this.getField(3);
395                return t.length;  
396            } catch (ClassCastException cce) {
397                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
398                throw new RuntimeException(cce);
399            } catch (HL7Exception he) {
400                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
401                throw new RuntimeException(he);
402            }
403        }
404    
405    
406    
407        /**
408         * Inserts a repetition of
409         * STF-3: "Staff Name" at a specific index
410         *
411         * @param rep The repetition index (0-indexed)
412         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
413         */
414        public XPN insertStaffName(int rep) throws HL7Exception { 
415            return (XPN) super.insertRepetition(3, rep);
416        }
417    
418    
419    
420        /**
421         * Inserts a repetition of
422         * STF-3: "Staff Name" at a specific index
423         *
424         * @param rep The repetition index (0-indexed)
425         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
426         */
427        public XPN insertStf3_StaffName(int rep) throws HL7Exception { 
428            return (XPN) super.insertRepetition(3, rep);
429        }
430    
431    
432        /**
433         * Removes a repetition of
434         * STF-3: "Staff Name" at a specific index
435         *
436         * @param rep The repetition index (0-indexed)
437         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
438         */
439        public XPN removeStaffName(int rep) throws HL7Exception { 
440            return (XPN) super.removeRepetition(3, rep);
441        }
442    
443    
444        /**
445         * Removes a repetition of
446         * STF-3: "Staff Name" at a specific index
447         *
448         * @param rep The repetition index (0-indexed)
449         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
450         */
451        public XPN removeStf3_StaffName(int rep) throws HL7Exception { 
452            return (XPN) super.removeRepetition(3, rep);
453        }
454    
455    
456    
457        /**
458         * Returns all repetitions of Staff Type (STF-4).
459         */
460        public IS[] getStaffType() {
461            IS[] ret = null;
462            try {
463                Type[] t = this.getField(4);  
464                ret = new IS[t.length];
465                for (int i = 0; i < ret.length; i++) {
466                    ret[i] = (IS)t[i];
467                }
468            } catch (ClassCastException cce) {
469                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
470                throw new RuntimeException(cce);
471            } catch (HL7Exception he) {
472                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
473                throw new RuntimeException(he);
474            }
475            return ret;
476        }
477    
478    
479        /**
480         * Returns a count of the current number of repetitions of Staff Type (STF-4).
481         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
482         * it will return zero.
483         */
484        public int getStaffTypeReps() {
485            IS[] ret = null;
486            try {
487                Type[] t = this.getField(4);
488                return t.length;  
489            } catch (ClassCastException cce) {
490                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
491                throw new RuntimeException(cce);
492            } catch (HL7Exception he) {
493                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
494                throw new RuntimeException(he);
495            }
496        }
497    
498    
499        /**
500         * Returns a specific repetition of
501         * STF-4: "Staff Type" - creates it if necessary
502         *
503         * @param rep The repetition index (0-indexed)
504         */
505        public IS getStaffType(int rep) { 
506            IS ret = null;
507            try {
508                Type t = this.getField(4, rep);
509                ret = (IS)t;
510            } catch (ClassCastException cce) {
511                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
512                throw new RuntimeException(cce);
513            } catch (HL7Exception he) {
514                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
515                throw new RuntimeException(he);
516            }
517            return ret;
518        }
519    
520        /**
521         * Returns a specific repetition of
522         * STF-4: "Staff Type" - creates it if necessary
523         *
524         * @param rep The repetition index (0-indexed)
525         */
526        public IS getStf4_StaffType(int rep) { 
527            IS ret = null;
528            try {
529                Type t = this.getField(4, rep);
530                ret = (IS)t;
531            } catch (ClassCastException cce) {
532                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
533                throw new RuntimeException(cce);
534            } catch (HL7Exception he) {
535                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
536                throw new RuntimeException(he);
537            }
538            return ret;
539        }
540    
541    
542        /**
543         * Returns a count of the current number of repetitions of Staff Type (STF-4).
544         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
545         * it will return zero.
546         */
547        public int getStf4_StaffTypeReps() {
548            IS[] ret = null;
549            try {
550                Type[] t = this.getField(4);
551                return t.length;  
552            } catch (ClassCastException cce) {
553                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
554                throw new RuntimeException(cce);
555            } catch (HL7Exception he) {
556                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
557                throw new RuntimeException(he);
558            }
559        }
560    
561    
562    
563        /**
564         * Inserts a repetition of
565         * STF-4: "Staff Type" at a specific index
566         *
567         * @param rep The repetition index (0-indexed)
568         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
569         */
570        public IS insertStaffType(int rep) throws HL7Exception { 
571            return (IS) super.insertRepetition(4, rep);
572        }
573    
574    
575    
576        /**
577         * Inserts a repetition of
578         * STF-4: "Staff Type" at a specific index
579         *
580         * @param rep The repetition index (0-indexed)
581         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
582         */
583        public IS insertStf4_StaffType(int rep) throws HL7Exception { 
584            return (IS) super.insertRepetition(4, rep);
585        }
586    
587    
588        /**
589         * Removes a repetition of
590         * STF-4: "Staff Type" at a specific index
591         *
592         * @param rep The repetition index (0-indexed)
593         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
594         */
595        public IS removeStaffType(int rep) throws HL7Exception { 
596            return (IS) super.removeRepetition(4, rep);
597        }
598    
599    
600        /**
601         * Removes a repetition of
602         * STF-4: "Staff Type" at a specific index
603         *
604         * @param rep The repetition index (0-indexed)
605         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
606         */
607        public IS removeStf4_StaffType(int rep) throws HL7Exception { 
608            return (IS) super.removeRepetition(4, rep);
609        }
610    
611    
612    
613    
614        /**
615         * Returns
616         * STF-5: "Administrative Sex" - creates it if necessary
617         */
618        public IS getAdministrativeSex() { 
619            IS ret = null;
620            try {
621                Type t = this.getField(5, 0);
622                ret = (IS)t;
623            } catch (ClassCastException cce) {
624                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
625                throw new RuntimeException(cce);
626            } catch (HL7Exception he) {
627                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
628                throw new RuntimeException(he);
629            }
630            return ret;
631        }
632    
633    
634        /**
635         * Returns
636         * STF-5: "Administrative Sex" - creates it if necessary
637         */
638        public IS getStf5_AdministrativeSex() { 
639            IS ret = null;
640            try {
641                Type t = this.getField(5, 0);
642                ret = (IS)t;
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            return ret;
651        }
652    
653    
654    
655        /**
656         * Returns
657         * STF-6: "Date/Time Of Birth" - creates it if necessary
658         */
659        public TS getDateTimeOfBirth() { 
660            TS ret = null;
661            try {
662                Type t = this.getField(6, 0);
663                ret = (TS)t;
664            } catch (ClassCastException cce) {
665                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
666                throw new RuntimeException(cce);
667            } catch (HL7Exception he) {
668                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
669                throw new RuntimeException(he);
670            }
671            return ret;
672        }
673    
674    
675        /**
676         * Returns
677         * STF-6: "Date/Time Of Birth" - creates it if necessary
678         */
679        public TS getStf6_DateTimeOfBirth() { 
680            TS ret = null;
681            try {
682                Type t = this.getField(6, 0);
683                ret = (TS)t;
684            } catch (ClassCastException cce) {
685                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
686                throw new RuntimeException(cce);
687            } catch (HL7Exception he) {
688                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
689                throw new RuntimeException(he);
690            }
691            return ret;
692        }
693    
694    
695    
696        /**
697         * Returns
698         * STF-7: "Active/Inactive Flag" - creates it if necessary
699         */
700        public ID getActiveInactiveFlag() { 
701            ID ret = null;
702            try {
703                Type t = this.getField(7, 0);
704                ret = (ID)t;
705            } catch (ClassCastException cce) {
706                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
707                throw new RuntimeException(cce);
708            } catch (HL7Exception he) {
709                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
710                throw new RuntimeException(he);
711            }
712            return ret;
713        }
714    
715    
716        /**
717         * Returns
718         * STF-7: "Active/Inactive Flag" - creates it if necessary
719         */
720        public ID getStf7_ActiveInactiveFlag() { 
721            ID ret = null;
722            try {
723                Type t = this.getField(7, 0);
724                ret = (ID)t;
725            } catch (ClassCastException cce) {
726                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
727                throw new RuntimeException(cce);
728            } catch (HL7Exception he) {
729                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
730                throw new RuntimeException(he);
731            }
732            return ret;
733        }
734    
735    
736        /**
737         * Returns all repetitions of Department (STF-8).
738         */
739        public CE[] getDepartment() {
740            CE[] ret = null;
741            try {
742                Type[] t = this.getField(8);  
743                ret = new CE[t.length];
744                for (int i = 0; i < ret.length; i++) {
745                    ret[i] = (CE)t[i];
746                }
747            } catch (ClassCastException cce) {
748                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
749                throw new RuntimeException(cce);
750            } catch (HL7Exception he) {
751                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
752                throw new RuntimeException(he);
753            }
754            return ret;
755        }
756    
757    
758        /**
759         * Returns a count of the current number of repetitions of Department (STF-8).
760         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
761         * it will return zero.
762         */
763        public int getDepartmentReps() {
764            CE[] ret = null;
765            try {
766                Type[] t = this.getField(8);
767                return t.length;  
768            } catch (ClassCastException cce) {
769                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
770                throw new RuntimeException(cce);
771            } catch (HL7Exception he) {
772                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
773                throw new RuntimeException(he);
774            }
775        }
776    
777    
778        /**
779         * Returns a specific repetition of
780         * STF-8: "Department" - creates it if necessary
781         *
782         * @param rep The repetition index (0-indexed)
783         */
784        public CE getDepartment(int rep) { 
785            CE ret = null;
786            try {
787                Type t = this.getField(8, rep);
788                ret = (CE)t;
789            } catch (ClassCastException cce) {
790                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
791                throw new RuntimeException(cce);
792            } catch (HL7Exception he) {
793                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
794                throw new RuntimeException(he);
795            }
796            return ret;
797        }
798    
799        /**
800         * Returns a specific repetition of
801         * STF-8: "Department" - creates it if necessary
802         *
803         * @param rep The repetition index (0-indexed)
804         */
805        public CE getStf8_Department(int rep) { 
806            CE ret = null;
807            try {
808                Type t = this.getField(8, rep);
809                ret = (CE)t;
810            } catch (ClassCastException cce) {
811                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
812                throw new RuntimeException(cce);
813            } catch (HL7Exception he) {
814                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
815                throw new RuntimeException(he);
816            }
817            return ret;
818        }
819    
820    
821        /**
822         * Returns a count of the current number of repetitions of Department (STF-8).
823         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
824         * it will return zero.
825         */
826        public int getStf8_DepartmentReps() {
827            CE[] ret = null;
828            try {
829                Type[] t = this.getField(8);
830                return t.length;  
831            } catch (ClassCastException cce) {
832                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
833                throw new RuntimeException(cce);
834            } catch (HL7Exception he) {
835                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
836                throw new RuntimeException(he);
837            }
838        }
839    
840    
841    
842        /**
843         * Inserts a repetition of
844         * STF-8: "Department" at a specific index
845         *
846         * @param rep The repetition index (0-indexed)
847         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
848         */
849        public CE insertDepartment(int rep) throws HL7Exception { 
850            return (CE) super.insertRepetition(8, rep);
851        }
852    
853    
854    
855        /**
856         * Inserts a repetition of
857         * STF-8: "Department" at a specific index
858         *
859         * @param rep The repetition index (0-indexed)
860         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
861         */
862        public CE insertStf8_Department(int rep) throws HL7Exception { 
863            return (CE) super.insertRepetition(8, rep);
864        }
865    
866    
867        /**
868         * Removes a repetition of
869         * STF-8: "Department" at a specific index
870         *
871         * @param rep The repetition index (0-indexed)
872         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
873         */
874        public CE removeDepartment(int rep) throws HL7Exception { 
875            return (CE) super.removeRepetition(8, rep);
876        }
877    
878    
879        /**
880         * Removes a repetition of
881         * STF-8: "Department" at a specific index
882         *
883         * @param rep The repetition index (0-indexed)
884         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
885         */
886        public CE removeStf8_Department(int rep) throws HL7Exception { 
887            return (CE) super.removeRepetition(8, rep);
888        }
889    
890    
891    
892        /**
893         * Returns all repetitions of Hospital Service (STF-9).
894         */
895        public CE[] getHospitalService() {
896            CE[] ret = null;
897            try {
898                Type[] t = this.getField(9);  
899                ret = new CE[t.length];
900                for (int i = 0; i < ret.length; i++) {
901                    ret[i] = (CE)t[i];
902                }
903            } catch (ClassCastException cce) {
904                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
905                throw new RuntimeException(cce);
906            } catch (HL7Exception he) {
907                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
908                throw new RuntimeException(he);
909            }
910            return ret;
911        }
912    
913    
914        /**
915         * Returns a count of the current number of repetitions of Hospital Service (STF-9).
916         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
917         * it will return zero.
918         */
919        public int getHospitalServiceReps() {
920            CE[] ret = null;
921            try {
922                Type[] t = this.getField(9);
923                return t.length;  
924            } catch (ClassCastException cce) {
925                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
926                throw new RuntimeException(cce);
927            } catch (HL7Exception he) {
928                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
929                throw new RuntimeException(he);
930            }
931        }
932    
933    
934        /**
935         * Returns a specific repetition of
936         * STF-9: "Hospital Service" - creates it if necessary
937         *
938         * @param rep The repetition index (0-indexed)
939         */
940        public CE getHospitalService(int rep) { 
941            CE ret = null;
942            try {
943                Type t = this.getField(9, rep);
944                ret = (CE)t;
945            } catch (ClassCastException cce) {
946                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
947                throw new RuntimeException(cce);
948            } catch (HL7Exception he) {
949                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
950                throw new RuntimeException(he);
951            }
952            return ret;
953        }
954    
955        /**
956         * Returns a specific repetition of
957         * STF-9: "Hospital Service" - creates it if necessary
958         *
959         * @param rep The repetition index (0-indexed)
960         */
961        public CE getStf9_HospitalService(int rep) { 
962            CE ret = null;
963            try {
964                Type t = this.getField(9, rep);
965                ret = (CE)t;
966            } catch (ClassCastException cce) {
967                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
968                throw new RuntimeException(cce);
969            } catch (HL7Exception he) {
970                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
971                throw new RuntimeException(he);
972            }
973            return ret;
974        }
975    
976    
977        /**
978         * Returns a count of the current number of repetitions of Hospital Service (STF-9).
979         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
980         * it will return zero.
981         */
982        public int getStf9_HospitalServiceReps() {
983            CE[] ret = null;
984            try {
985                Type[] t = this.getField(9);
986                return t.length;  
987            } catch (ClassCastException cce) {
988                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
989                throw new RuntimeException(cce);
990            } catch (HL7Exception he) {
991                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
992                throw new RuntimeException(he);
993            }
994        }
995    
996    
997    
998        /**
999         * Inserts a repetition of
1000         * STF-9: "Hospital Service" at a specific index
1001         *
1002         * @param rep The repetition index (0-indexed)
1003         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1004         */
1005        public CE insertHospitalService(int rep) throws HL7Exception { 
1006            return (CE) super.insertRepetition(9, rep);
1007        }
1008    
1009    
1010    
1011        /**
1012         * Inserts a repetition of
1013         * STF-9: "Hospital Service" at a specific index
1014         *
1015         * @param rep The repetition index (0-indexed)
1016         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1017         */
1018        public CE insertStf9_HospitalService(int rep) throws HL7Exception { 
1019            return (CE) super.insertRepetition(9, rep);
1020        }
1021    
1022    
1023        /**
1024         * Removes a repetition of
1025         * STF-9: "Hospital Service" at a specific index
1026         *
1027         * @param rep The repetition index (0-indexed)
1028         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1029         */
1030        public CE removeHospitalService(int rep) throws HL7Exception { 
1031            return (CE) super.removeRepetition(9, rep);
1032        }
1033    
1034    
1035        /**
1036         * Removes a repetition of
1037         * STF-9: "Hospital Service" at a specific index
1038         *
1039         * @param rep The repetition index (0-indexed)
1040         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1041         */
1042        public CE removeStf9_HospitalService(int rep) throws HL7Exception { 
1043            return (CE) super.removeRepetition(9, rep);
1044        }
1045    
1046    
1047    
1048        /**
1049         * Returns all repetitions of Phone (STF-10).
1050         */
1051        public XTN[] getPhone() {
1052            XTN[] ret = null;
1053            try {
1054                Type[] t = this.getField(10);  
1055                ret = new XTN[t.length];
1056                for (int i = 0; i < ret.length; i++) {
1057                    ret[i] = (XTN)t[i];
1058                }
1059            } catch (ClassCastException cce) {
1060                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1061                throw new RuntimeException(cce);
1062            } catch (HL7Exception he) {
1063                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1064                throw new RuntimeException(he);
1065            }
1066            return ret;
1067        }
1068    
1069    
1070        /**
1071         * Returns a count of the current number of repetitions of Phone (STF-10).
1072         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1073         * it will return zero.
1074         */
1075        public int getPhoneReps() {
1076            XTN[] ret = null;
1077            try {
1078                Type[] t = this.getField(10);
1079                return t.length;  
1080            } catch (ClassCastException cce) {
1081                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1082                throw new RuntimeException(cce);
1083            } catch (HL7Exception he) {
1084                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1085                throw new RuntimeException(he);
1086            }
1087        }
1088    
1089    
1090        /**
1091         * Returns a specific repetition of
1092         * STF-10: "Phone" - creates it if necessary
1093         *
1094         * @param rep The repetition index (0-indexed)
1095         */
1096        public XTN getPhone(int rep) { 
1097            XTN ret = null;
1098            try {
1099                Type t = this.getField(10, rep);
1100                ret = (XTN)t;
1101            } catch (ClassCastException cce) {
1102                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1103                throw new RuntimeException(cce);
1104            } catch (HL7Exception he) {
1105                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1106                throw new RuntimeException(he);
1107            }
1108            return ret;
1109        }
1110    
1111        /**
1112         * Returns a specific repetition of
1113         * STF-10: "Phone" - creates it if necessary
1114         *
1115         * @param rep The repetition index (0-indexed)
1116         */
1117        public XTN getStf10_Phone(int rep) { 
1118            XTN ret = null;
1119            try {
1120                Type t = this.getField(10, rep);
1121                ret = (XTN)t;
1122            } catch (ClassCastException cce) {
1123                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1124                throw new RuntimeException(cce);
1125            } catch (HL7Exception he) {
1126                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1127                throw new RuntimeException(he);
1128            }
1129            return ret;
1130        }
1131    
1132    
1133        /**
1134         * Returns a count of the current number of repetitions of Phone (STF-10).
1135         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1136         * it will return zero.
1137         */
1138        public int getStf10_PhoneReps() {
1139            XTN[] ret = null;
1140            try {
1141                Type[] t = this.getField(10);
1142                return t.length;  
1143            } catch (ClassCastException cce) {
1144                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1145                throw new RuntimeException(cce);
1146            } catch (HL7Exception he) {
1147                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1148                throw new RuntimeException(he);
1149            }
1150        }
1151    
1152    
1153    
1154        /**
1155         * Inserts a repetition of
1156         * STF-10: "Phone" at a specific index
1157         *
1158         * @param rep The repetition index (0-indexed)
1159         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1160         */
1161        public XTN insertPhone(int rep) throws HL7Exception { 
1162            return (XTN) super.insertRepetition(10, rep);
1163        }
1164    
1165    
1166    
1167        /**
1168         * Inserts a repetition of
1169         * STF-10: "Phone" at a specific index
1170         *
1171         * @param rep The repetition index (0-indexed)
1172         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1173         */
1174        public XTN insertStf10_Phone(int rep) throws HL7Exception { 
1175            return (XTN) super.insertRepetition(10, rep);
1176        }
1177    
1178    
1179        /**
1180         * Removes a repetition of
1181         * STF-10: "Phone" at a specific index
1182         *
1183         * @param rep The repetition index (0-indexed)
1184         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1185         */
1186        public XTN removePhone(int rep) throws HL7Exception { 
1187            return (XTN) super.removeRepetition(10, rep);
1188        }
1189    
1190    
1191        /**
1192         * Removes a repetition of
1193         * STF-10: "Phone" at a specific index
1194         *
1195         * @param rep The repetition index (0-indexed)
1196         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1197         */
1198        public XTN removeStf10_Phone(int rep) throws HL7Exception { 
1199            return (XTN) super.removeRepetition(10, rep);
1200        }
1201    
1202    
1203    
1204        /**
1205         * Returns all repetitions of Office/Home Address (STF-11).
1206         */
1207        public XAD[] getOfficeHomeAddress() {
1208            XAD[] ret = null;
1209            try {
1210                Type[] t = this.getField(11);  
1211                ret = new XAD[t.length];
1212                for (int i = 0; i < ret.length; i++) {
1213                    ret[i] = (XAD)t[i];
1214                }
1215            } catch (ClassCastException cce) {
1216                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1217                throw new RuntimeException(cce);
1218            } catch (HL7Exception he) {
1219                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1220                throw new RuntimeException(he);
1221            }
1222            return ret;
1223        }
1224    
1225    
1226        /**
1227         * Returns a count of the current number of repetitions of Office/Home Address (STF-11).
1228         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1229         * it will return zero.
1230         */
1231        public int getOfficeHomeAddressReps() {
1232            XAD[] ret = null;
1233            try {
1234                Type[] t = this.getField(11);
1235                return t.length;  
1236            } catch (ClassCastException cce) {
1237                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1238                throw new RuntimeException(cce);
1239            } catch (HL7Exception he) {
1240                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1241                throw new RuntimeException(he);
1242            }
1243        }
1244    
1245    
1246        /**
1247         * Returns a specific repetition of
1248         * STF-11: "Office/Home Address" - creates it if necessary
1249         *
1250         * @param rep The repetition index (0-indexed)
1251         */
1252        public XAD getOfficeHomeAddress(int rep) { 
1253            XAD ret = null;
1254            try {
1255                Type t = this.getField(11, rep);
1256                ret = (XAD)t;
1257            } catch (ClassCastException cce) {
1258                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1259                throw new RuntimeException(cce);
1260            } catch (HL7Exception he) {
1261                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1262                throw new RuntimeException(he);
1263            }
1264            return ret;
1265        }
1266    
1267        /**
1268         * Returns a specific repetition of
1269         * STF-11: "Office/Home Address" - creates it if necessary
1270         *
1271         * @param rep The repetition index (0-indexed)
1272         */
1273        public XAD getStf11_OfficeHomeAddress(int rep) { 
1274            XAD ret = null;
1275            try {
1276                Type t = this.getField(11, rep);
1277                ret = (XAD)t;
1278            } catch (ClassCastException cce) {
1279                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1280                throw new RuntimeException(cce);
1281            } catch (HL7Exception he) {
1282                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1283                throw new RuntimeException(he);
1284            }
1285            return ret;
1286        }
1287    
1288    
1289        /**
1290         * Returns a count of the current number of repetitions of Office/Home Address (STF-11).
1291         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1292         * it will return zero.
1293         */
1294        public int getStf11_OfficeHomeAddressReps() {
1295            XAD[] ret = null;
1296            try {
1297                Type[] t = this.getField(11);
1298                return t.length;  
1299            } catch (ClassCastException cce) {
1300                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1301                throw new RuntimeException(cce);
1302            } catch (HL7Exception he) {
1303                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1304                throw new RuntimeException(he);
1305            }
1306        }
1307    
1308    
1309    
1310        /**
1311         * Inserts a repetition of
1312         * STF-11: "Office/Home Address" at a specific index
1313         *
1314         * @param rep The repetition index (0-indexed)
1315         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1316         */
1317        public XAD insertOfficeHomeAddress(int rep) throws HL7Exception { 
1318            return (XAD) super.insertRepetition(11, rep);
1319        }
1320    
1321    
1322    
1323        /**
1324         * Inserts a repetition of
1325         * STF-11: "Office/Home Address" at a specific index
1326         *
1327         * @param rep The repetition index (0-indexed)
1328         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1329         */
1330        public XAD insertStf11_OfficeHomeAddress(int rep) throws HL7Exception { 
1331            return (XAD) super.insertRepetition(11, rep);
1332        }
1333    
1334    
1335        /**
1336         * Removes a repetition of
1337         * STF-11: "Office/Home Address" at a specific index
1338         *
1339         * @param rep The repetition index (0-indexed)
1340         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1341         */
1342        public XAD removeOfficeHomeAddress(int rep) throws HL7Exception { 
1343            return (XAD) super.removeRepetition(11, rep);
1344        }
1345    
1346    
1347        /**
1348         * Removes a repetition of
1349         * STF-11: "Office/Home Address" at a specific index
1350         *
1351         * @param rep The repetition index (0-indexed)
1352         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1353         */
1354        public XAD removeStf11_OfficeHomeAddress(int rep) throws HL7Exception { 
1355            return (XAD) super.removeRepetition(11, rep);
1356        }
1357    
1358    
1359    
1360        /**
1361         * Returns all repetitions of Institution Activation Date (STF-12).
1362         */
1363        public DIN[] getInstitutionActivationDate() {
1364            DIN[] ret = null;
1365            try {
1366                Type[] t = this.getField(12);  
1367                ret = new DIN[t.length];
1368                for (int i = 0; i < ret.length; i++) {
1369                    ret[i] = (DIN)t[i];
1370                }
1371            } catch (ClassCastException cce) {
1372                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1373                throw new RuntimeException(cce);
1374            } catch (HL7Exception he) {
1375                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1376                throw new RuntimeException(he);
1377            }
1378            return ret;
1379        }
1380    
1381    
1382        /**
1383         * Returns a count of the current number of repetitions of Institution Activation Date (STF-12).
1384         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1385         * it will return zero.
1386         */
1387        public int getInstitutionActivationDateReps() {
1388            DIN[] ret = null;
1389            try {
1390                Type[] t = this.getField(12);
1391                return t.length;  
1392            } catch (ClassCastException cce) {
1393                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1394                throw new RuntimeException(cce);
1395            } catch (HL7Exception he) {
1396                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1397                throw new RuntimeException(he);
1398            }
1399        }
1400    
1401    
1402        /**
1403         * Returns a specific repetition of
1404         * STF-12: "Institution Activation Date" - creates it if necessary
1405         *
1406         * @param rep The repetition index (0-indexed)
1407         */
1408        public DIN getInstitutionActivationDate(int rep) { 
1409            DIN ret = null;
1410            try {
1411                Type t = this.getField(12, rep);
1412                ret = (DIN)t;
1413            } catch (ClassCastException cce) {
1414                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1415                throw new RuntimeException(cce);
1416            } catch (HL7Exception he) {
1417                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1418                throw new RuntimeException(he);
1419            }
1420            return ret;
1421        }
1422    
1423        /**
1424         * Returns a specific repetition of
1425         * STF-12: "Institution Activation Date" - creates it if necessary
1426         *
1427         * @param rep The repetition index (0-indexed)
1428         */
1429        public DIN getStf12_InstitutionActivationDate(int rep) { 
1430            DIN ret = null;
1431            try {
1432                Type t = this.getField(12, rep);
1433                ret = (DIN)t;
1434            } catch (ClassCastException cce) {
1435                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1436                throw new RuntimeException(cce);
1437            } catch (HL7Exception he) {
1438                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1439                throw new RuntimeException(he);
1440            }
1441            return ret;
1442        }
1443    
1444    
1445        /**
1446         * Returns a count of the current number of repetitions of Institution Activation Date (STF-12).
1447         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1448         * it will return zero.
1449         */
1450        public int getStf12_InstitutionActivationDateReps() {
1451            DIN[] ret = null;
1452            try {
1453                Type[] t = this.getField(12);
1454                return t.length;  
1455            } catch (ClassCastException cce) {
1456                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1457                throw new RuntimeException(cce);
1458            } catch (HL7Exception he) {
1459                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1460                throw new RuntimeException(he);
1461            }
1462        }
1463    
1464    
1465    
1466        /**
1467         * Inserts a repetition of
1468         * STF-12: "Institution Activation Date" at a specific index
1469         *
1470         * @param rep The repetition index (0-indexed)
1471         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1472         */
1473        public DIN insertInstitutionActivationDate(int rep) throws HL7Exception { 
1474            return (DIN) super.insertRepetition(12, rep);
1475        }
1476    
1477    
1478    
1479        /**
1480         * Inserts a repetition of
1481         * STF-12: "Institution Activation Date" at a specific index
1482         *
1483         * @param rep The repetition index (0-indexed)
1484         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1485         */
1486        public DIN insertStf12_InstitutionActivationDate(int rep) throws HL7Exception { 
1487            return (DIN) super.insertRepetition(12, rep);
1488        }
1489    
1490    
1491        /**
1492         * Removes a repetition of
1493         * STF-12: "Institution Activation Date" at a specific index
1494         *
1495         * @param rep The repetition index (0-indexed)
1496         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1497         */
1498        public DIN removeInstitutionActivationDate(int rep) throws HL7Exception { 
1499            return (DIN) super.removeRepetition(12, rep);
1500        }
1501    
1502    
1503        /**
1504         * Removes a repetition of
1505         * STF-12: "Institution Activation Date" at a specific index
1506         *
1507         * @param rep The repetition index (0-indexed)
1508         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1509         */
1510        public DIN removeStf12_InstitutionActivationDate(int rep) throws HL7Exception { 
1511            return (DIN) super.removeRepetition(12, rep);
1512        }
1513    
1514    
1515    
1516        /**
1517         * Returns all repetitions of Institution Inactivation Date (STF-13).
1518         */
1519        public DIN[] getInstitutionInactivationDate() {
1520            DIN[] ret = null;
1521            try {
1522                Type[] t = this.getField(13);  
1523                ret = new DIN[t.length];
1524                for (int i = 0; i < ret.length; i++) {
1525                    ret[i] = (DIN)t[i];
1526                }
1527            } catch (ClassCastException cce) {
1528                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1529                throw new RuntimeException(cce);
1530            } catch (HL7Exception he) {
1531                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1532                throw new RuntimeException(he);
1533            }
1534            return ret;
1535        }
1536    
1537    
1538        /**
1539         * Returns a count of the current number of repetitions of Institution Inactivation Date (STF-13).
1540         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1541         * it will return zero.
1542         */
1543        public int getInstitutionInactivationDateReps() {
1544            DIN[] ret = null;
1545            try {
1546                Type[] t = this.getField(13);
1547                return t.length;  
1548            } catch (ClassCastException cce) {
1549                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1550                throw new RuntimeException(cce);
1551            } catch (HL7Exception he) {
1552                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1553                throw new RuntimeException(he);
1554            }
1555        }
1556    
1557    
1558        /**
1559         * Returns a specific repetition of
1560         * STF-13: "Institution Inactivation Date" - creates it if necessary
1561         *
1562         * @param rep The repetition index (0-indexed)
1563         */
1564        public DIN getInstitutionInactivationDate(int rep) { 
1565            DIN ret = null;
1566            try {
1567                Type t = this.getField(13, rep);
1568                ret = (DIN)t;
1569            } catch (ClassCastException cce) {
1570                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1571                throw new RuntimeException(cce);
1572            } catch (HL7Exception he) {
1573                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1574                throw new RuntimeException(he);
1575            }
1576            return ret;
1577        }
1578    
1579        /**
1580         * Returns a specific repetition of
1581         * STF-13: "Institution Inactivation Date" - creates it if necessary
1582         *
1583         * @param rep The repetition index (0-indexed)
1584         */
1585        public DIN getStf13_InstitutionInactivationDate(int rep) { 
1586            DIN ret = null;
1587            try {
1588                Type t = this.getField(13, rep);
1589                ret = (DIN)t;
1590            } catch (ClassCastException cce) {
1591                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1592                throw new RuntimeException(cce);
1593            } catch (HL7Exception he) {
1594                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1595                throw new RuntimeException(he);
1596            }
1597            return ret;
1598        }
1599    
1600    
1601        /**
1602         * Returns a count of the current number of repetitions of Institution Inactivation Date (STF-13).
1603         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1604         * it will return zero.
1605         */
1606        public int getStf13_InstitutionInactivationDateReps() {
1607            DIN[] ret = null;
1608            try {
1609                Type[] t = this.getField(13);
1610                return t.length;  
1611            } catch (ClassCastException cce) {
1612                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1613                throw new RuntimeException(cce);
1614            } catch (HL7Exception he) {
1615                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1616                throw new RuntimeException(he);
1617            }
1618        }
1619    
1620    
1621    
1622        /**
1623         * Inserts a repetition of
1624         * STF-13: "Institution Inactivation Date" at a specific index
1625         *
1626         * @param rep The repetition index (0-indexed)
1627         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1628         */
1629        public DIN insertInstitutionInactivationDate(int rep) throws HL7Exception { 
1630            return (DIN) super.insertRepetition(13, rep);
1631        }
1632    
1633    
1634    
1635        /**
1636         * Inserts a repetition of
1637         * STF-13: "Institution Inactivation Date" at a specific index
1638         *
1639         * @param rep The repetition index (0-indexed)
1640         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1641         */
1642        public DIN insertStf13_InstitutionInactivationDate(int rep) throws HL7Exception { 
1643            return (DIN) super.insertRepetition(13, rep);
1644        }
1645    
1646    
1647        /**
1648         * Removes a repetition of
1649         * STF-13: "Institution Inactivation Date" at a specific index
1650         *
1651         * @param rep The repetition index (0-indexed)
1652         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1653         */
1654        public DIN removeInstitutionInactivationDate(int rep) throws HL7Exception { 
1655            return (DIN) super.removeRepetition(13, rep);
1656        }
1657    
1658    
1659        /**
1660         * Removes a repetition of
1661         * STF-13: "Institution Inactivation Date" at a specific index
1662         *
1663         * @param rep The repetition index (0-indexed)
1664         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1665         */
1666        public DIN removeStf13_InstitutionInactivationDate(int rep) throws HL7Exception { 
1667            return (DIN) super.removeRepetition(13, rep);
1668        }
1669    
1670    
1671    
1672        /**
1673         * Returns all repetitions of Backup Person ID (STF-14).
1674         */
1675        public CE[] getBackupPersonID() {
1676            CE[] ret = null;
1677            try {
1678                Type[] t = this.getField(14);  
1679                ret = new CE[t.length];
1680                for (int i = 0; i < ret.length; i++) {
1681                    ret[i] = (CE)t[i];
1682                }
1683            } catch (ClassCastException cce) {
1684                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1685                throw new RuntimeException(cce);
1686            } catch (HL7Exception he) {
1687                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1688                throw new RuntimeException(he);
1689            }
1690            return ret;
1691        }
1692    
1693    
1694        /**
1695         * Returns a count of the current number of repetitions of Backup Person ID (STF-14).
1696         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1697         * it will return zero.
1698         */
1699        public int getBackupPersonIDReps() {
1700            CE[] ret = null;
1701            try {
1702                Type[] t = this.getField(14);
1703                return t.length;  
1704            } catch (ClassCastException cce) {
1705                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1706                throw new RuntimeException(cce);
1707            } catch (HL7Exception he) {
1708                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1709                throw new RuntimeException(he);
1710            }
1711        }
1712    
1713    
1714        /**
1715         * Returns a specific repetition of
1716         * STF-14: "Backup Person ID" - creates it if necessary
1717         *
1718         * @param rep The repetition index (0-indexed)
1719         */
1720        public CE getBackupPersonID(int rep) { 
1721            CE ret = null;
1722            try {
1723                Type t = this.getField(14, rep);
1724                ret = (CE)t;
1725            } catch (ClassCastException cce) {
1726                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1727                throw new RuntimeException(cce);
1728            } catch (HL7Exception he) {
1729                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1730                throw new RuntimeException(he);
1731            }
1732            return ret;
1733        }
1734    
1735        /**
1736         * Returns a specific repetition of
1737         * STF-14: "Backup Person ID" - creates it if necessary
1738         *
1739         * @param rep The repetition index (0-indexed)
1740         */
1741        public CE getStf14_BackupPersonID(int rep) { 
1742            CE ret = null;
1743            try {
1744                Type t = this.getField(14, rep);
1745                ret = (CE)t;
1746            } catch (ClassCastException cce) {
1747                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1748                throw new RuntimeException(cce);
1749            } catch (HL7Exception he) {
1750                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1751                throw new RuntimeException(he);
1752            }
1753            return ret;
1754        }
1755    
1756    
1757        /**
1758         * Returns a count of the current number of repetitions of Backup Person ID (STF-14).
1759         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1760         * it will return zero.
1761         */
1762        public int getStf14_BackupPersonIDReps() {
1763            CE[] ret = null;
1764            try {
1765                Type[] t = this.getField(14);
1766                return t.length;  
1767            } catch (ClassCastException cce) {
1768                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1769                throw new RuntimeException(cce);
1770            } catch (HL7Exception he) {
1771                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1772                throw new RuntimeException(he);
1773            }
1774        }
1775    
1776    
1777    
1778        /**
1779         * Inserts a repetition of
1780         * STF-14: "Backup Person ID" at a specific index
1781         *
1782         * @param rep The repetition index (0-indexed)
1783         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1784         */
1785        public CE insertBackupPersonID(int rep) throws HL7Exception { 
1786            return (CE) super.insertRepetition(14, rep);
1787        }
1788    
1789    
1790    
1791        /**
1792         * Inserts a repetition of
1793         * STF-14: "Backup Person ID" at a specific index
1794         *
1795         * @param rep The repetition index (0-indexed)
1796         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1797         */
1798        public CE insertStf14_BackupPersonID(int rep) throws HL7Exception { 
1799            return (CE) super.insertRepetition(14, rep);
1800        }
1801    
1802    
1803        /**
1804         * Removes a repetition of
1805         * STF-14: "Backup Person ID" at a specific index
1806         *
1807         * @param rep The repetition index (0-indexed)
1808         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1809         */
1810        public CE removeBackupPersonID(int rep) throws HL7Exception { 
1811            return (CE) super.removeRepetition(14, rep);
1812        }
1813    
1814    
1815        /**
1816         * Removes a repetition of
1817         * STF-14: "Backup Person ID" at a specific index
1818         *
1819         * @param rep The repetition index (0-indexed)
1820         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1821         */
1822        public CE removeStf14_BackupPersonID(int rep) throws HL7Exception { 
1823            return (CE) super.removeRepetition(14, rep);
1824        }
1825    
1826    
1827    
1828        /**
1829         * Returns all repetitions of E-Mail Address (STF-15).
1830         */
1831        public ST[] getEMailAddress() {
1832            ST[] ret = null;
1833            try {
1834                Type[] t = this.getField(15);  
1835                ret = new ST[t.length];
1836                for (int i = 0; i < ret.length; i++) {
1837                    ret[i] = (ST)t[i];
1838                }
1839            } catch (ClassCastException cce) {
1840                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1841                throw new RuntimeException(cce);
1842            } catch (HL7Exception he) {
1843                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1844                throw new RuntimeException(he);
1845            }
1846            return ret;
1847        }
1848    
1849    
1850        /**
1851         * Returns a count of the current number of repetitions of E-Mail Address (STF-15).
1852         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1853         * it will return zero.
1854         */
1855        public int getEMailAddressReps() {
1856            ST[] ret = null;
1857            try {
1858                Type[] t = this.getField(15);
1859                return t.length;  
1860            } catch (ClassCastException cce) {
1861                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1862                throw new RuntimeException(cce);
1863            } catch (HL7Exception he) {
1864                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1865                throw new RuntimeException(he);
1866            }
1867        }
1868    
1869    
1870        /**
1871         * Returns a specific repetition of
1872         * STF-15: "E-Mail Address" - creates it if necessary
1873         *
1874         * @param rep The repetition index (0-indexed)
1875         */
1876        public ST getEMailAddress(int rep) { 
1877            ST ret = null;
1878            try {
1879                Type t = this.getField(15, rep);
1880                ret = (ST)t;
1881            } catch (ClassCastException cce) {
1882                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1883                throw new RuntimeException(cce);
1884            } catch (HL7Exception he) {
1885                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1886                throw new RuntimeException(he);
1887            }
1888            return ret;
1889        }
1890    
1891        /**
1892         * Returns a specific repetition of
1893         * STF-15: "E-Mail Address" - creates it if necessary
1894         *
1895         * @param rep The repetition index (0-indexed)
1896         */
1897        public ST getStf15_EMailAddress(int rep) { 
1898            ST ret = null;
1899            try {
1900                Type t = this.getField(15, rep);
1901                ret = (ST)t;
1902            } catch (ClassCastException cce) {
1903                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1904                throw new RuntimeException(cce);
1905            } catch (HL7Exception he) {
1906                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1907                throw new RuntimeException(he);
1908            }
1909            return ret;
1910        }
1911    
1912    
1913        /**
1914         * Returns a count of the current number of repetitions of E-Mail Address (STF-15).
1915         * This method does not create a repetition, so if no repetitions have currently been defined or accessed,
1916         * it will return zero.
1917         */
1918        public int getStf15_EMailAddressReps() {
1919            ST[] ret = null;
1920            try {
1921                Type[] t = this.getField(15);
1922                return t.length;  
1923            } catch (ClassCastException cce) {
1924                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1925                throw new RuntimeException(cce);
1926            } catch (HL7Exception he) {
1927                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1928                throw new RuntimeException(he);
1929            }
1930        }
1931    
1932    
1933    
1934        /**
1935         * Inserts a repetition of
1936         * STF-15: "E-Mail Address" at a specific index
1937         *
1938         * @param rep The repetition index (0-indexed)
1939         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1940         */
1941        public ST insertEMailAddress(int rep) throws HL7Exception { 
1942            return (ST) super.insertRepetition(15, rep);
1943        }
1944    
1945    
1946    
1947        /**
1948         * Inserts a repetition of
1949         * STF-15: "E-Mail Address" at a specific index
1950         *
1951         * @param rep The repetition index (0-indexed)
1952         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1953         */
1954        public ST insertStf15_EMailAddress(int rep) throws HL7Exception { 
1955            return (ST) super.insertRepetition(15, rep);
1956        }
1957    
1958    
1959        /**
1960         * Removes a repetition of
1961         * STF-15: "E-Mail Address" at a specific index
1962         *
1963         * @param rep The repetition index (0-indexed)
1964         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1965         */
1966        public ST removeEMailAddress(int rep) throws HL7Exception { 
1967            return (ST) super.removeRepetition(15, rep);
1968        }
1969    
1970    
1971        /**
1972         * Removes a repetition of
1973         * STF-15: "E-Mail Address" at a specific index
1974         *
1975         * @param rep The repetition index (0-indexed)
1976         * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions)
1977         */
1978        public ST removeStf15_EMailAddress(int rep) throws HL7Exception { 
1979            return (ST) super.removeRepetition(15, rep);
1980        }
1981    
1982    
1983    
1984    
1985        /**
1986         * Returns
1987         * STF-16: "Preferred Method of Contact" - creates it if necessary
1988         */
1989        public CE getPreferredMethodOfContact() { 
1990            CE ret = null;
1991            try {
1992                Type t = this.getField(16, 0);
1993                ret = (CE)t;
1994            } catch (ClassCastException cce) {
1995                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
1996                throw new RuntimeException(cce);
1997            } catch (HL7Exception he) {
1998                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
1999                throw new RuntimeException(he);
2000            }
2001            return ret;
2002        }
2003    
2004    
2005        /**
2006         * Returns
2007         * STF-16: "Preferred Method of Contact" - creates it if necessary
2008         */
2009        public CE getStf16_PreferredMethodOfContact() { 
2010            CE ret = null;
2011            try {
2012                Type t = this.getField(16, 0);
2013                ret = (CE)t;
2014            } catch (ClassCastException cce) {
2015                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2016                throw new RuntimeException(cce);
2017            } catch (HL7Exception he) {
2018                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2019                throw new RuntimeException(he);
2020            }
2021            return ret;
2022        }
2023    
2024    
2025    
2026        /**
2027         * Returns
2028         * STF-17: "Marital Status" - creates it if necessary
2029         */
2030        public CE getMaritalStatus() { 
2031            CE ret = null;
2032            try {
2033                Type t = this.getField(17, 0);
2034                ret = (CE)t;
2035            } catch (ClassCastException cce) {
2036                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2037                throw new RuntimeException(cce);
2038            } catch (HL7Exception he) {
2039                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2040                throw new RuntimeException(he);
2041            }
2042            return ret;
2043        }
2044    
2045    
2046        /**
2047         * Returns
2048         * STF-17: "Marital Status" - creates it if necessary
2049         */
2050        public CE getStf17_MaritalStatus() { 
2051            CE ret = null;
2052            try {
2053                Type t = this.getField(17, 0);
2054                ret = (CE)t;
2055            } catch (ClassCastException cce) {
2056                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2057                throw new RuntimeException(cce);
2058            } catch (HL7Exception he) {
2059                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2060                throw new RuntimeException(he);
2061            }
2062            return ret;
2063        }
2064    
2065    
2066    
2067        /**
2068         * Returns
2069         * STF-18: "Job Title" - creates it if necessary
2070         */
2071        public ST getJobTitle() { 
2072            ST ret = null;
2073            try {
2074                Type t = this.getField(18, 0);
2075                ret = (ST)t;
2076            } catch (ClassCastException cce) {
2077                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2078                throw new RuntimeException(cce);
2079            } catch (HL7Exception he) {
2080                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2081                throw new RuntimeException(he);
2082            }
2083            return ret;
2084        }
2085    
2086    
2087        /**
2088         * Returns
2089         * STF-18: "Job Title" - creates it if necessary
2090         */
2091        public ST getStf18_JobTitle() { 
2092            ST ret = null;
2093            try {
2094                Type t = this.getField(18, 0);
2095                ret = (ST)t;
2096            } catch (ClassCastException cce) {
2097                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2098                throw new RuntimeException(cce);
2099            } catch (HL7Exception he) {
2100                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2101                throw new RuntimeException(he);
2102            }
2103            return ret;
2104        }
2105    
2106    
2107    
2108        /**
2109         * Returns
2110         * STF-19: "Job Code/Class" - creates it if necessary
2111         */
2112        public JCC getJobCodeClass() { 
2113            JCC ret = null;
2114            try {
2115                Type t = this.getField(19, 0);
2116                ret = (JCC)t;
2117            } catch (ClassCastException cce) {
2118                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2119                throw new RuntimeException(cce);
2120            } catch (HL7Exception he) {
2121                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2122                throw new RuntimeException(he);
2123            }
2124            return ret;
2125        }
2126    
2127    
2128        /**
2129         * Returns
2130         * STF-19: "Job Code/Class" - creates it if necessary
2131         */
2132        public JCC getStf19_JobCodeClass() { 
2133            JCC ret = null;
2134            try {
2135                Type t = this.getField(19, 0);
2136                ret = (JCC)t;
2137            } catch (ClassCastException cce) {
2138                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2139                throw new RuntimeException(cce);
2140            } catch (HL7Exception he) {
2141                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2142                throw new RuntimeException(he);
2143            }
2144            return ret;
2145        }
2146    
2147    
2148    
2149        /**
2150         * Returns
2151         * STF-20: "Employment Status Code" - creates it if necessary
2152         */
2153        public CE getEmploymentStatusCode() { 
2154            CE ret = null;
2155            try {
2156                Type t = this.getField(20, 0);
2157                ret = (CE)t;
2158            } catch (ClassCastException cce) {
2159                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2160                throw new RuntimeException(cce);
2161            } catch (HL7Exception he) {
2162                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2163                throw new RuntimeException(he);
2164            }
2165            return ret;
2166        }
2167    
2168    
2169        /**
2170         * Returns
2171         * STF-20: "Employment Status Code" - creates it if necessary
2172         */
2173        public CE getStf20_EmploymentStatusCode() { 
2174            CE ret = null;
2175            try {
2176                Type t = this.getField(20, 0);
2177                ret = (CE)t;
2178            } catch (ClassCastException cce) {
2179                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2180                throw new RuntimeException(cce);
2181            } catch (HL7Exception he) {
2182                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2183                throw new RuntimeException(he);
2184            }
2185            return ret;
2186        }
2187    
2188    
2189    
2190        /**
2191         * Returns
2192         * STF-21: "Additional Insured on  Auto" - creates it if necessary
2193         */
2194        public ID getAdditionalInsuredOnAuto() { 
2195            ID ret = null;
2196            try {
2197                Type t = this.getField(21, 0);
2198                ret = (ID)t;
2199            } catch (ClassCastException cce) {
2200                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2201                throw new RuntimeException(cce);
2202            } catch (HL7Exception he) {
2203                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2204                throw new RuntimeException(he);
2205            }
2206            return ret;
2207        }
2208    
2209    
2210        /**
2211         * Returns
2212         * STF-21: "Additional Insured on  Auto" - creates it if necessary
2213         */
2214        public ID getStf21_AdditionalInsuredOnAuto() { 
2215            ID ret = null;
2216            try {
2217                Type t = this.getField(21, 0);
2218                ret = (ID)t;
2219            } catch (ClassCastException cce) {
2220                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2221                throw new RuntimeException(cce);
2222            } catch (HL7Exception he) {
2223                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2224                throw new RuntimeException(he);
2225            }
2226            return ret;
2227        }
2228    
2229    
2230    
2231        /**
2232         * Returns
2233         * STF-22: "Driver's License Number - Staff" - creates it if necessary
2234         */
2235        public DLN getDriverSLicenseNumberStaff() { 
2236            DLN ret = null;
2237            try {
2238                Type t = this.getField(22, 0);
2239                ret = (DLN)t;
2240            } catch (ClassCastException cce) {
2241                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2242                throw new RuntimeException(cce);
2243            } catch (HL7Exception he) {
2244                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2245                throw new RuntimeException(he);
2246            }
2247            return ret;
2248        }
2249    
2250    
2251        /**
2252         * Returns
2253         * STF-22: "Driver's License Number - Staff" - creates it if necessary
2254         */
2255        public DLN getStf22_DriverSLicenseNumberStaff() { 
2256            DLN ret = null;
2257            try {
2258                Type t = this.getField(22, 0);
2259                ret = (DLN)t;
2260            } catch (ClassCastException cce) {
2261                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2262                throw new RuntimeException(cce);
2263            } catch (HL7Exception he) {
2264                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2265                throw new RuntimeException(he);
2266            }
2267            return ret;
2268        }
2269    
2270    
2271    
2272        /**
2273         * Returns
2274         * STF-23: "Copy  Auto Ins" - creates it if necessary
2275         */
2276        public ID getCopyAutoIns() { 
2277            ID ret = null;
2278            try {
2279                Type t = this.getField(23, 0);
2280                ret = (ID)t;
2281            } catch (ClassCastException cce) {
2282                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2283                throw new RuntimeException(cce);
2284            } catch (HL7Exception he) {
2285                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2286                throw new RuntimeException(he);
2287            }
2288            return ret;
2289        }
2290    
2291    
2292        /**
2293         * Returns
2294         * STF-23: "Copy  Auto Ins" - creates it if necessary
2295         */
2296        public ID getStf23_CopyAutoIns() { 
2297            ID ret = null;
2298            try {
2299                Type t = this.getField(23, 0);
2300                ret = (ID)t;
2301            } catch (ClassCastException cce) {
2302                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2303                throw new RuntimeException(cce);
2304            } catch (HL7Exception he) {
2305                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2306                throw new RuntimeException(he);
2307            }
2308            return ret;
2309        }
2310    
2311    
2312    
2313        /**
2314         * Returns
2315         * STF-24: "Auto Ins. Expires" - creates it if necessary
2316         */
2317        public DT getAutoInsExpires() { 
2318            DT ret = null;
2319            try {
2320                Type t = this.getField(24, 0);
2321                ret = (DT)t;
2322            } catch (ClassCastException cce) {
2323                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2324                throw new RuntimeException(cce);
2325            } catch (HL7Exception he) {
2326                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2327                throw new RuntimeException(he);
2328            }
2329            return ret;
2330        }
2331    
2332    
2333        /**
2334         * Returns
2335         * STF-24: "Auto Ins. Expires" - creates it if necessary
2336         */
2337        public DT getStf24_AutoInsExpires() { 
2338            DT ret = null;
2339            try {
2340                Type t = this.getField(24, 0);
2341                ret = (DT)t;
2342            } catch (ClassCastException cce) {
2343                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2344                throw new RuntimeException(cce);
2345            } catch (HL7Exception he) {
2346                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2347                throw new RuntimeException(he);
2348            }
2349            return ret;
2350        }
2351    
2352    
2353    
2354        /**
2355         * Returns
2356         * STF-25: "Date Last DMV Review" - creates it if necessary
2357         */
2358        public DT getDateLastDMVReview() { 
2359            DT ret = null;
2360            try {
2361                Type t = this.getField(25, 0);
2362                ret = (DT)t;
2363            } catch (ClassCastException cce) {
2364                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2365                throw new RuntimeException(cce);
2366            } catch (HL7Exception he) {
2367                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2368                throw new RuntimeException(he);
2369            }
2370            return ret;
2371        }
2372    
2373    
2374        /**
2375         * Returns
2376         * STF-25: "Date Last DMV Review" - creates it if necessary
2377         */
2378        public DT getStf25_DateLastDMVReview() { 
2379            DT ret = null;
2380            try {
2381                Type t = this.getField(25, 0);
2382                ret = (DT)t;
2383            } catch (ClassCastException cce) {
2384                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2385                throw new RuntimeException(cce);
2386            } catch (HL7Exception he) {
2387                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2388                throw new RuntimeException(he);
2389            }
2390            return ret;
2391        }
2392    
2393    
2394    
2395        /**
2396         * Returns
2397         * STF-26: "Date Next DMV Review" - creates it if necessary
2398         */
2399        public DT getDateNextDMVReview() { 
2400            DT ret = null;
2401            try {
2402                Type t = this.getField(26, 0);
2403                ret = (DT)t;
2404            } catch (ClassCastException cce) {
2405                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2406                throw new RuntimeException(cce);
2407            } catch (HL7Exception he) {
2408                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2409                throw new RuntimeException(he);
2410            }
2411            return ret;
2412        }
2413    
2414    
2415        /**
2416         * Returns
2417         * STF-26: "Date Next DMV Review" - creates it if necessary
2418         */
2419        public DT getStf26_DateNextDMVReview() { 
2420            DT ret = null;
2421            try {
2422                Type t = this.getField(26, 0);
2423                ret = (DT)t;
2424            } catch (ClassCastException cce) {
2425                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2426                throw new RuntimeException(cce);
2427            } catch (HL7Exception he) {
2428                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2429                throw new RuntimeException(he);
2430            }
2431            return ret;
2432        }
2433    
2434    
2435    
2436        /**
2437         * Returns
2438         * STF-27: "Race" - creates it if necessary
2439         */
2440        public CE getRace() { 
2441            CE ret = null;
2442            try {
2443                Type t = this.getField(27, 0);
2444                ret = (CE)t;
2445            } catch (ClassCastException cce) {
2446                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2447                throw new RuntimeException(cce);
2448            } catch (HL7Exception he) {
2449                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2450                throw new RuntimeException(he);
2451            }
2452            return ret;
2453        }
2454    
2455    
2456        /**
2457         * Returns
2458         * STF-27: "Race" - creates it if necessary
2459         */
2460        public CE getStf27_Race() { 
2461            CE ret = null;
2462            try {
2463                Type t = this.getField(27, 0);
2464                ret = (CE)t;
2465            } catch (ClassCastException cce) {
2466                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2467                throw new RuntimeException(cce);
2468            } catch (HL7Exception he) {
2469                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2470                throw new RuntimeException(he);
2471            }
2472            return ret;
2473        }
2474    
2475    
2476    
2477        /**
2478         * Returns
2479         * STF-28: "Ethnic Group" - creates it if necessary
2480         */
2481        public CE getEthnicGroup() { 
2482            CE ret = null;
2483            try {
2484                Type t = this.getField(28, 0);
2485                ret = (CE)t;
2486            } catch (ClassCastException cce) {
2487                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2488                throw new RuntimeException(cce);
2489            } catch (HL7Exception he) {
2490                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2491                throw new RuntimeException(he);
2492            }
2493            return ret;
2494        }
2495    
2496    
2497        /**
2498         * Returns
2499         * STF-28: "Ethnic Group" - creates it if necessary
2500         */
2501        public CE getStf28_EthnicGroup() { 
2502            CE ret = null;
2503            try {
2504                Type t = this.getField(28, 0);
2505                ret = (CE)t;
2506            } catch (ClassCastException cce) {
2507                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2508                throw new RuntimeException(cce);
2509            } catch (HL7Exception he) {
2510                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2511                throw new RuntimeException(he);
2512            }
2513            return ret;
2514        }
2515    
2516    
2517    
2518        /**
2519         * Returns
2520         * STF-29: "Re-activation Approval Indicator" - creates it if necessary
2521         */
2522        public ID getReActivationApprovalIndicator() { 
2523            ID ret = null;
2524            try {
2525                Type t = this.getField(29, 0);
2526                ret = (ID)t;
2527            } catch (ClassCastException cce) {
2528                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2529                throw new RuntimeException(cce);
2530            } catch (HL7Exception he) {
2531                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2532                throw new RuntimeException(he);
2533            }
2534            return ret;
2535        }
2536    
2537    
2538        /**
2539         * Returns
2540         * STF-29: "Re-activation Approval Indicator" - creates it if necessary
2541         */
2542        public ID getStf29_ReActivationApprovalIndicator() { 
2543            ID ret = null;
2544            try {
2545                Type t = this.getField(29, 0);
2546                ret = (ID)t;
2547            } catch (ClassCastException cce) {
2548                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", cce);
2549                throw new RuntimeException(cce);
2550            } catch (HL7Exception he) {
2551                HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value.  This is a bug.", he);
2552                throw new RuntimeException(he);
2553            }
2554            return ret;
2555        }
2556    
2557    
2558    
2559    
2560    
2561        /** {@inheritDoc} */   
2562        protected Type createNewTypeWithoutReflection(int field) {
2563           switch (field) {
2564              case 0: return new CE(getMessage());
2565              case 1: return new CX(getMessage());
2566              case 2: return new XPN(getMessage());
2567              case 3: return new IS(getMessage(), new Integer( 182 ));
2568              case 4: return new IS(getMessage(), new Integer( 1 ));
2569              case 5: return new TS(getMessage());
2570              case 6: return new ID(getMessage(), new Integer( 183 ));
2571              case 7: return new CE(getMessage());
2572              case 8: return new CE(getMessage());
2573              case 9: return new XTN(getMessage());
2574              case 10: return new XAD(getMessage());
2575              case 11: return new DIN(getMessage());
2576              case 12: return new DIN(getMessage());
2577              case 13: return new CE(getMessage());
2578              case 14: return new ST(getMessage());
2579              case 15: return new CE(getMessage());
2580              case 16: return new CE(getMessage());
2581              case 17: return new ST(getMessage());
2582              case 18: return new JCC(getMessage());
2583              case 19: return new CE(getMessage());
2584              case 20: return new ID(getMessage(), new Integer( 136 ));
2585              case 21: return new DLN(getMessage());
2586              case 22: return new ID(getMessage(), new Integer( 136 ));
2587              case 23: return new DT(getMessage());
2588              case 24: return new DT(getMessage());
2589              case 25: return new DT(getMessage());
2590              case 26: return new CE(getMessage());
2591              case 27: return new CE(getMessage());
2592              case 28: return new ID(getMessage(), new Integer( 136 ));
2593              default: return null;
2594           }
2595       }
2596    
2597    
2598    }
2599