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 * The contents of this file are subject to the Mozilla Public License Version 1.1 
008 * (the "License"); you may not use this file except in compliance with the License. 
009 * You may obtain a copy of the License at http://www.mozilla.org/MPL/ 
010 * Software distributed under the License is distributed on an "AS IS" basis, 
011 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the 
012 * specific language governing rights and limitations under the License. 
013 * 
014 * The Original Code is "[file_name]".  Description: 
015 * "[one_line_description]" 
016 * 
017 * The Initial Developer of the Original Code is University Health Network. Copyright (C) 
018 * 2012.  All Rights Reserved. 
019 * 
020 * Contributor(s): ______________________________________. 
021 * 
022 * Alternatively, the contents of this file may be used under the terms of the 
023 * GNU General Public License (the  "GPL"), in which case the provisions of the GPL are 
024 * applicable instead of those above.  If you wish to allow use of your version of this 
025 * file only under the terms of the GPL and not to allow others to use your version 
026 * of this file under the MPL, indicate your decision by deleting  the provisions above 
027 * and replace  them with the notice and other provisions required by the GPL License.  
028 * If you do not delete the provisions above, a recipient may use your version of 
029 * this file under either the MPL or the GPL. 
030 * 
031 */
032
033
034package ca.uhn.hl7v2.model.v27.message;
035
036import ca.uhn.hl7v2.model.v27.group.*;
037import ca.uhn.hl7v2.model.v27.segment.*;
038
039import ca.uhn.hl7v2.HL7Exception;
040import ca.uhn.hl7v2.parser.ModelClassFactory;
041import ca.uhn.hl7v2.parser.DefaultModelClassFactory;
042import ca.uhn.hl7v2.model.*;
043
044
045/**
046 * <p>Represents a CCR_I16 message structure (see chapter 11.6.2). This structure contains the 
047 * following elements: </p>
048 * <ul>
049                                 * <li>1: MSH (Message Header) <b> </b> </li>
050                                 * <li>2: SFT (Software Segment) <b>optional repeating</b> </li>
051                                 * <li>3: UAC (User Authentication Credential Segment) <b>optional </b> </li>
052                                 * <li>4: RF1 (Referral Information) <b> repeating</b> </li>
053                                 * <li>5: CCR_I16_PROVIDER_CONTACT (a Group object) <b> repeating</b> </li>
054                                 * <li>6: CCR_I16_CLINICAL_ORDER (a Group object) <b>optional repeating</b> </li>
055                                 * <li>7: CCR_I16_PATIENT (a Group object) <b> repeating</b> </li>
056                                 * <li>8: NK1 (Next of Kin / Associated Parties) <b>optional repeating</b> </li>
057                                 * <li>9: CCR_I16_INSURANCE (a Group object) <b>optional repeating</b> </li>
058                                 * <li>10: CCR_I16_APPOINTMENT_HISTORY (a Group object) <b>optional repeating</b> </li>
059                                 * <li>11: CCR_I16_CLINICAL_HISTORY (a Group object) <b>optional repeating</b> </li>
060                                 * <li>12: CCR_I16_PATIENT_VISITS (a Group object) <b> repeating</b> </li>
061                                 * <li>13: CCR_I16_MEDICATION_HISTORY (a Group object) <b>optional repeating</b> </li>
062                                 * <li>14: CCR_I16_PROBLEM (a Group object) <b>optional repeating</b> </li>
063                                 * <li>15: CCR_I16_GOAL (a Group object) <b>optional repeating</b> </li>
064                                 * <li>16: CCR_I16_PATHWAY (a Group object) <b>optional repeating</b> </li>
065                                 * <li>17: REL (Clinical Relationship Segment) <b>optional repeating</b> </li>
066 * </ul>
067 */
068//@SuppressWarnings("unused")
069public class CCR_I16 extends AbstractMessage  {
070
071    /**
072     * Creates a new CCR_I16 message with DefaultModelClassFactory. 
073     */ 
074    public CCR_I16() { 
075       this(new DefaultModelClassFactory());
076    }
077
078    /** 
079     * Creates a new CCR_I16 message with custom ModelClassFactory.
080     */
081    public CCR_I16(ModelClassFactory factory) {
082       super(factory);
083       init(factory);
084    }
085
086    private void init(ModelClassFactory factory) {
087       try {
088                          this.add(MSH.class, true, false);
089                                  this.add(SFT.class, false, true);
090                                  this.add(UAC.class, false, false);
091                                  this.add(RF1.class, true, true);
092                                  this.add(CCR_I16_PROVIDER_CONTACT.class, true, true);
093                                  this.add(CCR_I16_CLINICAL_ORDER.class, false, true);
094                                  this.add(CCR_I16_PATIENT.class, true, true);
095                                  this.add(NK1.class, false, true);
096                                  this.add(CCR_I16_INSURANCE.class, false, true);
097                                  this.add(CCR_I16_APPOINTMENT_HISTORY.class, false, true);
098                                  this.add(CCR_I16_CLINICAL_HISTORY.class, false, true);
099                                  this.add(CCR_I16_PATIENT_VISITS.class, true, true);
100                                  this.add(CCR_I16_MEDICATION_HISTORY.class, false, true);
101                                  this.add(CCR_I16_PROBLEM.class, false, true);
102                                  this.add(CCR_I16_GOAL.class, false, true);
103                                  this.add(CCR_I16_PATHWAY.class, false, true);
104                                  this.add(REL.class, false, true);
105               } catch(HL7Exception e) {
106          log.error("Unexpected error creating CCR_I16 - this is probably a bug in the source code generator.", e);
107       }
108    }
109
110
111    /** 
112     * Returns "2.7"
113     */
114    public String getVersion() {
115       return "2.7";
116    }
117
118
119
120
121    /**
122     * <p>
123     * Returns
124     * MSH (Message Header) - creates it if necessary
125     * </p>
126     * 
127     *
128     */
129    public MSH getMSH() { 
130       return getTyped("MSH", MSH.class);
131    }
132
133
134
135
136
137    /**
138     * <p>
139     * Returns
140     * the first repetition of 
141     * SFT (Software Segment) - creates it if necessary
142     * </p>
143     * 
144     *
145     */
146    public SFT getSFT() { 
147       return getTyped("SFT", SFT.class);
148    }
149
150
151    /**
152     * <p>
153     * Returns a specific repetition of
154     * SFT (Software Segment) - creates it if necessary
155     * </p>
156     * 
157     *
158     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
159     * @throws HL7Exception if the repetition requested is more than one 
160     *     greater than the number of existing repetitions.
161     */
162    public SFT getSFT(int rep) { 
163       return getTyped("SFT", rep, SFT.class);
164    }
165
166    /** 
167     * <p>
168     * Returns the number of existing repetitions of SFT 
169     * </p>
170     * 
171     */ 
172    public int getSFTReps() { 
173        return getReps("SFT");
174    } 
175
176    /** 
177     * <p>
178     * Returns a non-modifiable List containing all current existing repetitions of SFT.
179     * <p>
180     * <p>
181     * Note that unlike {@link #getSFT()}, this method will not create any reps
182     * if none are already present, so an empty list may be returned.
183     * </p>
184     * 
185     */ 
186    public java.util.List<SFT> getSFTAll() throws HL7Exception {
187        return getAllAsList("SFT", SFT.class);
188    } 
189
190    /**
191     * <p>
192     * Inserts a specific repetition of SFT (Software Segment)
193     * </p>
194     * 
195     *
196     * @see AbstractGroup#insertRepetition(Structure, int) 
197     */
198    public void insertSFT(SFT structure, int rep) throws HL7Exception { 
199       super.insertRepetition( "SFT", structure, rep);
200    }
201
202
203    /**
204     * <p>
205     * Inserts a specific repetition of SFT (Software Segment)
206     * </p>
207     * 
208     *
209     * @see AbstractGroup#insertRepetition(Structure, int) 
210     */
211    public SFT insertSFT(int rep) throws HL7Exception { 
212       return (SFT)super.insertRepetition("SFT", rep);
213    }
214
215
216    /**
217     * <p>
218     * Removes a specific repetition of SFT (Software Segment)
219     * </p>
220     * 
221     *
222     * @see AbstractGroup#removeRepetition(String, int) 
223     */
224    public SFT removeSFT(int rep) throws HL7Exception { 
225       return (SFT)super.removeRepetition("SFT", rep);
226    }
227
228
229
230
231    /**
232     * <p>
233     * Returns
234     * UAC (User Authentication Credential Segment) - creates it if necessary
235     * </p>
236     * 
237     *
238     */
239    public UAC getUAC() { 
240       return getTyped("UAC", UAC.class);
241    }
242
243
244
245
246
247    /**
248     * <p>
249     * Returns
250     * the first repetition of 
251     * RF1 (Referral Information) - creates it if necessary
252     * </p>
253     * 
254     *
255     */
256    public RF1 getRF1() { 
257       return getTyped("RF1", RF1.class);
258    }
259
260
261    /**
262     * <p>
263     * Returns a specific repetition of
264     * RF1 (Referral Information) - creates it if necessary
265     * </p>
266     * 
267     *
268     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
269     * @throws HL7Exception if the repetition requested is more than one 
270     *     greater than the number of existing repetitions.
271     */
272    public RF1 getRF1(int rep) { 
273       return getTyped("RF1", rep, RF1.class);
274    }
275
276    /** 
277     * <p>
278     * Returns the number of existing repetitions of RF1 
279     * </p>
280     * 
281     */ 
282    public int getRF1Reps() { 
283        return getReps("RF1");
284    } 
285
286    /** 
287     * <p>
288     * Returns a non-modifiable List containing all current existing repetitions of RF1.
289     * <p>
290     * <p>
291     * Note that unlike {@link #getRF1()}, this method will not create any reps
292     * if none are already present, so an empty list may be returned.
293     * </p>
294     * 
295     */ 
296    public java.util.List<RF1> getRF1All() throws HL7Exception {
297        return getAllAsList("RF1", RF1.class);
298    } 
299
300    /**
301     * <p>
302     * Inserts a specific repetition of RF1 (Referral Information)
303     * </p>
304     * 
305     *
306     * @see AbstractGroup#insertRepetition(Structure, int) 
307     */
308    public void insertRF1(RF1 structure, int rep) throws HL7Exception { 
309       super.insertRepetition( "RF1", structure, rep);
310    }
311
312
313    /**
314     * <p>
315     * Inserts a specific repetition of RF1 (Referral Information)
316     * </p>
317     * 
318     *
319     * @see AbstractGroup#insertRepetition(Structure, int) 
320     */
321    public RF1 insertRF1(int rep) throws HL7Exception { 
322       return (RF1)super.insertRepetition("RF1", rep);
323    }
324
325
326    /**
327     * <p>
328     * Removes a specific repetition of RF1 (Referral Information)
329     * </p>
330     * 
331     *
332     * @see AbstractGroup#removeRepetition(String, int) 
333     */
334    public RF1 removeRF1(int rep) throws HL7Exception { 
335       return (RF1)super.removeRepetition("RF1", rep);
336    }
337
338
339
340
341    /**
342     * <p>
343     * Returns
344     * the first repetition of 
345     * PROVIDER_CONTACT (a Group object) - creates it if necessary
346     * </p>
347     * 
348     *
349     */
350    public CCR_I16_PROVIDER_CONTACT getPROVIDER_CONTACT() { 
351       return getTyped("PROVIDER_CONTACT", CCR_I16_PROVIDER_CONTACT.class);
352    }
353
354
355    /**
356     * <p>
357     * Returns a specific repetition of
358     * PROVIDER_CONTACT (a Group object) - creates it if necessary
359     * </p>
360     * 
361     *
362     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
363     * @throws HL7Exception if the repetition requested is more than one 
364     *     greater than the number of existing repetitions.
365     */
366    public CCR_I16_PROVIDER_CONTACT getPROVIDER_CONTACT(int rep) { 
367       return getTyped("PROVIDER_CONTACT", rep, CCR_I16_PROVIDER_CONTACT.class);
368    }
369
370    /** 
371     * <p>
372     * Returns the number of existing repetitions of PROVIDER_CONTACT 
373     * </p>
374     * 
375     */ 
376    public int getPROVIDER_CONTACTReps() { 
377        return getReps("PROVIDER_CONTACT");
378    } 
379
380    /** 
381     * <p>
382     * Returns a non-modifiable List containing all current existing repetitions of PROVIDER_CONTACT.
383     * <p>
384     * <p>
385     * Note that unlike {@link #getPROVIDER_CONTACT()}, this method will not create any reps
386     * if none are already present, so an empty list may be returned.
387     * </p>
388     * 
389     */ 
390    public java.util.List<CCR_I16_PROVIDER_CONTACT> getPROVIDER_CONTACTAll() throws HL7Exception {
391        return getAllAsList("PROVIDER_CONTACT", CCR_I16_PROVIDER_CONTACT.class);
392    } 
393
394    /**
395     * <p>
396     * Inserts a specific repetition of PROVIDER_CONTACT (a Group object)
397     * </p>
398     * 
399     *
400     * @see AbstractGroup#insertRepetition(Structure, int) 
401     */
402    public void insertPROVIDER_CONTACT(CCR_I16_PROVIDER_CONTACT structure, int rep) throws HL7Exception { 
403       super.insertRepetition( "PROVIDER_CONTACT", structure, rep);
404    }
405
406
407    /**
408     * <p>
409     * Inserts a specific repetition of PROVIDER_CONTACT (a Group object)
410     * </p>
411     * 
412     *
413     * @see AbstractGroup#insertRepetition(Structure, int) 
414     */
415    public CCR_I16_PROVIDER_CONTACT insertPROVIDER_CONTACT(int rep) throws HL7Exception { 
416       return (CCR_I16_PROVIDER_CONTACT)super.insertRepetition("PROVIDER_CONTACT", rep);
417    }
418
419
420    /**
421     * <p>
422     * Removes a specific repetition of PROVIDER_CONTACT (a Group object)
423     * </p>
424     * 
425     *
426     * @see AbstractGroup#removeRepetition(String, int) 
427     */
428    public CCR_I16_PROVIDER_CONTACT removePROVIDER_CONTACT(int rep) throws HL7Exception { 
429       return (CCR_I16_PROVIDER_CONTACT)super.removeRepetition("PROVIDER_CONTACT", rep);
430    }
431
432
433
434
435    /**
436     * <p>
437     * Returns
438     * the first repetition of 
439     * CLINICAL_ORDER (a Group object) - creates it if necessary
440     * </p>
441     * 
442     *
443     */
444    public CCR_I16_CLINICAL_ORDER getCLINICAL_ORDER() { 
445       return getTyped("CLINICAL_ORDER", CCR_I16_CLINICAL_ORDER.class);
446    }
447
448
449    /**
450     * <p>
451     * Returns a specific repetition of
452     * CLINICAL_ORDER (a Group object) - creates it if necessary
453     * </p>
454     * 
455     *
456     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
457     * @throws HL7Exception if the repetition requested is more than one 
458     *     greater than the number of existing repetitions.
459     */
460    public CCR_I16_CLINICAL_ORDER getCLINICAL_ORDER(int rep) { 
461       return getTyped("CLINICAL_ORDER", rep, CCR_I16_CLINICAL_ORDER.class);
462    }
463
464    /** 
465     * <p>
466     * Returns the number of existing repetitions of CLINICAL_ORDER 
467     * </p>
468     * 
469     */ 
470    public int getCLINICAL_ORDERReps() { 
471        return getReps("CLINICAL_ORDER");
472    } 
473
474    /** 
475     * <p>
476     * Returns a non-modifiable List containing all current existing repetitions of CLINICAL_ORDER.
477     * <p>
478     * <p>
479     * Note that unlike {@link #getCLINICAL_ORDER()}, this method will not create any reps
480     * if none are already present, so an empty list may be returned.
481     * </p>
482     * 
483     */ 
484    public java.util.List<CCR_I16_CLINICAL_ORDER> getCLINICAL_ORDERAll() throws HL7Exception {
485        return getAllAsList("CLINICAL_ORDER", CCR_I16_CLINICAL_ORDER.class);
486    } 
487
488    /**
489     * <p>
490     * Inserts a specific repetition of CLINICAL_ORDER (a Group object)
491     * </p>
492     * 
493     *
494     * @see AbstractGroup#insertRepetition(Structure, int) 
495     */
496    public void insertCLINICAL_ORDER(CCR_I16_CLINICAL_ORDER structure, int rep) throws HL7Exception { 
497       super.insertRepetition( "CLINICAL_ORDER", structure, rep);
498    }
499
500
501    /**
502     * <p>
503     * Inserts a specific repetition of CLINICAL_ORDER (a Group object)
504     * </p>
505     * 
506     *
507     * @see AbstractGroup#insertRepetition(Structure, int) 
508     */
509    public CCR_I16_CLINICAL_ORDER insertCLINICAL_ORDER(int rep) throws HL7Exception { 
510       return (CCR_I16_CLINICAL_ORDER)super.insertRepetition("CLINICAL_ORDER", rep);
511    }
512
513
514    /**
515     * <p>
516     * Removes a specific repetition of CLINICAL_ORDER (a Group object)
517     * </p>
518     * 
519     *
520     * @see AbstractGroup#removeRepetition(String, int) 
521     */
522    public CCR_I16_CLINICAL_ORDER removeCLINICAL_ORDER(int rep) throws HL7Exception { 
523       return (CCR_I16_CLINICAL_ORDER)super.removeRepetition("CLINICAL_ORDER", rep);
524    }
525
526
527
528
529    /**
530     * <p>
531     * Returns
532     * the first repetition of 
533     * PATIENT (a Group object) - creates it if necessary
534     * </p>
535     * 
536     *
537     */
538    public CCR_I16_PATIENT getPATIENT() { 
539       return getTyped("PATIENT", CCR_I16_PATIENT.class);
540    }
541
542
543    /**
544     * <p>
545     * Returns a specific repetition of
546     * PATIENT (a Group object) - creates it if necessary
547     * </p>
548     * 
549     *
550     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
551     * @throws HL7Exception if the repetition requested is more than one 
552     *     greater than the number of existing repetitions.
553     */
554    public CCR_I16_PATIENT getPATIENT(int rep) { 
555       return getTyped("PATIENT", rep, CCR_I16_PATIENT.class);
556    }
557
558    /** 
559     * <p>
560     * Returns the number of existing repetitions of PATIENT 
561     * </p>
562     * 
563     */ 
564    public int getPATIENTReps() { 
565        return getReps("PATIENT");
566    } 
567
568    /** 
569     * <p>
570     * Returns a non-modifiable List containing all current existing repetitions of PATIENT.
571     * <p>
572     * <p>
573     * Note that unlike {@link #getPATIENT()}, this method will not create any reps
574     * if none are already present, so an empty list may be returned.
575     * </p>
576     * 
577     */ 
578    public java.util.List<CCR_I16_PATIENT> getPATIENTAll() throws HL7Exception {
579        return getAllAsList("PATIENT", CCR_I16_PATIENT.class);
580    } 
581
582    /**
583     * <p>
584     * Inserts a specific repetition of PATIENT (a Group object)
585     * </p>
586     * 
587     *
588     * @see AbstractGroup#insertRepetition(Structure, int) 
589     */
590    public void insertPATIENT(CCR_I16_PATIENT structure, int rep) throws HL7Exception { 
591       super.insertRepetition( "PATIENT", structure, rep);
592    }
593
594
595    /**
596     * <p>
597     * Inserts a specific repetition of PATIENT (a Group object)
598     * </p>
599     * 
600     *
601     * @see AbstractGroup#insertRepetition(Structure, int) 
602     */
603    public CCR_I16_PATIENT insertPATIENT(int rep) throws HL7Exception { 
604       return (CCR_I16_PATIENT)super.insertRepetition("PATIENT", rep);
605    }
606
607
608    /**
609     * <p>
610     * Removes a specific repetition of PATIENT (a Group object)
611     * </p>
612     * 
613     *
614     * @see AbstractGroup#removeRepetition(String, int) 
615     */
616    public CCR_I16_PATIENT removePATIENT(int rep) throws HL7Exception { 
617       return (CCR_I16_PATIENT)super.removeRepetition("PATIENT", rep);
618    }
619
620
621
622
623    /**
624     * <p>
625     * Returns
626     * the first repetition of 
627     * NK1 (Next of Kin / Associated Parties) - creates it if necessary
628     * </p>
629     * 
630     *
631     */
632    public NK1 getNK1() { 
633       return getTyped("NK1", NK1.class);
634    }
635
636
637    /**
638     * <p>
639     * Returns a specific repetition of
640     * NK1 (Next of Kin / Associated Parties) - creates it if necessary
641     * </p>
642     * 
643     *
644     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
645     * @throws HL7Exception if the repetition requested is more than one 
646     *     greater than the number of existing repetitions.
647     */
648    public NK1 getNK1(int rep) { 
649       return getTyped("NK1", rep, NK1.class);
650    }
651
652    /** 
653     * <p>
654     * Returns the number of existing repetitions of NK1 
655     * </p>
656     * 
657     */ 
658    public int getNK1Reps() { 
659        return getReps("NK1");
660    } 
661
662    /** 
663     * <p>
664     * Returns a non-modifiable List containing all current existing repetitions of NK1.
665     * <p>
666     * <p>
667     * Note that unlike {@link #getNK1()}, this method will not create any reps
668     * if none are already present, so an empty list may be returned.
669     * </p>
670     * 
671     */ 
672    public java.util.List<NK1> getNK1All() throws HL7Exception {
673        return getAllAsList("NK1", NK1.class);
674    } 
675
676    /**
677     * <p>
678     * Inserts a specific repetition of NK1 (Next of Kin / Associated Parties)
679     * </p>
680     * 
681     *
682     * @see AbstractGroup#insertRepetition(Structure, int) 
683     */
684    public void insertNK1(NK1 structure, int rep) throws HL7Exception { 
685       super.insertRepetition( "NK1", structure, rep);
686    }
687
688
689    /**
690     * <p>
691     * Inserts a specific repetition of NK1 (Next of Kin / Associated Parties)
692     * </p>
693     * 
694     *
695     * @see AbstractGroup#insertRepetition(Structure, int) 
696     */
697    public NK1 insertNK1(int rep) throws HL7Exception { 
698       return (NK1)super.insertRepetition("NK1", rep);
699    }
700
701
702    /**
703     * <p>
704     * Removes a specific repetition of NK1 (Next of Kin / Associated Parties)
705     * </p>
706     * 
707     *
708     * @see AbstractGroup#removeRepetition(String, int) 
709     */
710    public NK1 removeNK1(int rep) throws HL7Exception { 
711       return (NK1)super.removeRepetition("NK1", rep);
712    }
713
714
715
716
717    /**
718     * <p>
719     * Returns
720     * the first repetition of 
721     * INSURANCE (a Group object) - creates it if necessary
722     * </p>
723     * 
724     *
725     */
726    public CCR_I16_INSURANCE getINSURANCE() { 
727       return getTyped("INSURANCE", CCR_I16_INSURANCE.class);
728    }
729
730
731    /**
732     * <p>
733     * Returns a specific repetition of
734     * INSURANCE (a Group object) - creates it if necessary
735     * </p>
736     * 
737     *
738     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
739     * @throws HL7Exception if the repetition requested is more than one 
740     *     greater than the number of existing repetitions.
741     */
742    public CCR_I16_INSURANCE getINSURANCE(int rep) { 
743       return getTyped("INSURANCE", rep, CCR_I16_INSURANCE.class);
744    }
745
746    /** 
747     * <p>
748     * Returns the number of existing repetitions of INSURANCE 
749     * </p>
750     * 
751     */ 
752    public int getINSURANCEReps() { 
753        return getReps("INSURANCE");
754    } 
755
756    /** 
757     * <p>
758     * Returns a non-modifiable List containing all current existing repetitions of INSURANCE.
759     * <p>
760     * <p>
761     * Note that unlike {@link #getINSURANCE()}, this method will not create any reps
762     * if none are already present, so an empty list may be returned.
763     * </p>
764     * 
765     */ 
766    public java.util.List<CCR_I16_INSURANCE> getINSURANCEAll() throws HL7Exception {
767        return getAllAsList("INSURANCE", CCR_I16_INSURANCE.class);
768    } 
769
770    /**
771     * <p>
772     * Inserts a specific repetition of INSURANCE (a Group object)
773     * </p>
774     * 
775     *
776     * @see AbstractGroup#insertRepetition(Structure, int) 
777     */
778    public void insertINSURANCE(CCR_I16_INSURANCE structure, int rep) throws HL7Exception { 
779       super.insertRepetition( "INSURANCE", structure, rep);
780    }
781
782
783    /**
784     * <p>
785     * Inserts a specific repetition of INSURANCE (a Group object)
786     * </p>
787     * 
788     *
789     * @see AbstractGroup#insertRepetition(Structure, int) 
790     */
791    public CCR_I16_INSURANCE insertINSURANCE(int rep) throws HL7Exception { 
792       return (CCR_I16_INSURANCE)super.insertRepetition("INSURANCE", rep);
793    }
794
795
796    /**
797     * <p>
798     * Removes a specific repetition of INSURANCE (a Group object)
799     * </p>
800     * 
801     *
802     * @see AbstractGroup#removeRepetition(String, int) 
803     */
804    public CCR_I16_INSURANCE removeINSURANCE(int rep) throws HL7Exception { 
805       return (CCR_I16_INSURANCE)super.removeRepetition("INSURANCE", rep);
806    }
807
808
809
810
811    /**
812     * <p>
813     * Returns
814     * the first repetition of 
815     * APPOINTMENT_HISTORY (a Group object) - creates it if necessary
816     * </p>
817     * 
818     *
819     */
820    public CCR_I16_APPOINTMENT_HISTORY getAPPOINTMENT_HISTORY() { 
821       return getTyped("APPOINTMENT_HISTORY", CCR_I16_APPOINTMENT_HISTORY.class);
822    }
823
824
825    /**
826     * <p>
827     * Returns a specific repetition of
828     * APPOINTMENT_HISTORY (a Group object) - creates it if necessary
829     * </p>
830     * 
831     *
832     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
833     * @throws HL7Exception if the repetition requested is more than one 
834     *     greater than the number of existing repetitions.
835     */
836    public CCR_I16_APPOINTMENT_HISTORY getAPPOINTMENT_HISTORY(int rep) { 
837       return getTyped("APPOINTMENT_HISTORY", rep, CCR_I16_APPOINTMENT_HISTORY.class);
838    }
839
840    /** 
841     * <p>
842     * Returns the number of existing repetitions of APPOINTMENT_HISTORY 
843     * </p>
844     * 
845     */ 
846    public int getAPPOINTMENT_HISTORYReps() { 
847        return getReps("APPOINTMENT_HISTORY");
848    } 
849
850    /** 
851     * <p>
852     * Returns a non-modifiable List containing all current existing repetitions of APPOINTMENT_HISTORY.
853     * <p>
854     * <p>
855     * Note that unlike {@link #getAPPOINTMENT_HISTORY()}, this method will not create any reps
856     * if none are already present, so an empty list may be returned.
857     * </p>
858     * 
859     */ 
860    public java.util.List<CCR_I16_APPOINTMENT_HISTORY> getAPPOINTMENT_HISTORYAll() throws HL7Exception {
861        return getAllAsList("APPOINTMENT_HISTORY", CCR_I16_APPOINTMENT_HISTORY.class);
862    } 
863
864    /**
865     * <p>
866     * Inserts a specific repetition of APPOINTMENT_HISTORY (a Group object)
867     * </p>
868     * 
869     *
870     * @see AbstractGroup#insertRepetition(Structure, int) 
871     */
872    public void insertAPPOINTMENT_HISTORY(CCR_I16_APPOINTMENT_HISTORY structure, int rep) throws HL7Exception { 
873       super.insertRepetition( "APPOINTMENT_HISTORY", structure, rep);
874    }
875
876
877    /**
878     * <p>
879     * Inserts a specific repetition of APPOINTMENT_HISTORY (a Group object)
880     * </p>
881     * 
882     *
883     * @see AbstractGroup#insertRepetition(Structure, int) 
884     */
885    public CCR_I16_APPOINTMENT_HISTORY insertAPPOINTMENT_HISTORY(int rep) throws HL7Exception { 
886       return (CCR_I16_APPOINTMENT_HISTORY)super.insertRepetition("APPOINTMENT_HISTORY", rep);
887    }
888
889
890    /**
891     * <p>
892     * Removes a specific repetition of APPOINTMENT_HISTORY (a Group object)
893     * </p>
894     * 
895     *
896     * @see AbstractGroup#removeRepetition(String, int) 
897     */
898    public CCR_I16_APPOINTMENT_HISTORY removeAPPOINTMENT_HISTORY(int rep) throws HL7Exception { 
899       return (CCR_I16_APPOINTMENT_HISTORY)super.removeRepetition("APPOINTMENT_HISTORY", rep);
900    }
901
902
903
904
905    /**
906     * <p>
907     * Returns
908     * the first repetition of 
909     * CLINICAL_HISTORY (a Group object) - creates it if necessary
910     * </p>
911     * 
912     *
913     */
914    public CCR_I16_CLINICAL_HISTORY getCLINICAL_HISTORY() { 
915       return getTyped("CLINICAL_HISTORY", CCR_I16_CLINICAL_HISTORY.class);
916    }
917
918
919    /**
920     * <p>
921     * Returns a specific repetition of
922     * CLINICAL_HISTORY (a Group object) - creates it if necessary
923     * </p>
924     * 
925     *
926     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
927     * @throws HL7Exception if the repetition requested is more than one 
928     *     greater than the number of existing repetitions.
929     */
930    public CCR_I16_CLINICAL_HISTORY getCLINICAL_HISTORY(int rep) { 
931       return getTyped("CLINICAL_HISTORY", rep, CCR_I16_CLINICAL_HISTORY.class);
932    }
933
934    /** 
935     * <p>
936     * Returns the number of existing repetitions of CLINICAL_HISTORY 
937     * </p>
938     * 
939     */ 
940    public int getCLINICAL_HISTORYReps() { 
941        return getReps("CLINICAL_HISTORY");
942    } 
943
944    /** 
945     * <p>
946     * Returns a non-modifiable List containing all current existing repetitions of CLINICAL_HISTORY.
947     * <p>
948     * <p>
949     * Note that unlike {@link #getCLINICAL_HISTORY()}, this method will not create any reps
950     * if none are already present, so an empty list may be returned.
951     * </p>
952     * 
953     */ 
954    public java.util.List<CCR_I16_CLINICAL_HISTORY> getCLINICAL_HISTORYAll() throws HL7Exception {
955        return getAllAsList("CLINICAL_HISTORY", CCR_I16_CLINICAL_HISTORY.class);
956    } 
957
958    /**
959     * <p>
960     * Inserts a specific repetition of CLINICAL_HISTORY (a Group object)
961     * </p>
962     * 
963     *
964     * @see AbstractGroup#insertRepetition(Structure, int) 
965     */
966    public void insertCLINICAL_HISTORY(CCR_I16_CLINICAL_HISTORY structure, int rep) throws HL7Exception { 
967       super.insertRepetition( "CLINICAL_HISTORY", structure, rep);
968    }
969
970
971    /**
972     * <p>
973     * Inserts a specific repetition of CLINICAL_HISTORY (a Group object)
974     * </p>
975     * 
976     *
977     * @see AbstractGroup#insertRepetition(Structure, int) 
978     */
979    public CCR_I16_CLINICAL_HISTORY insertCLINICAL_HISTORY(int rep) throws HL7Exception { 
980       return (CCR_I16_CLINICAL_HISTORY)super.insertRepetition("CLINICAL_HISTORY", rep);
981    }
982
983
984    /**
985     * <p>
986     * Removes a specific repetition of CLINICAL_HISTORY (a Group object)
987     * </p>
988     * 
989     *
990     * @see AbstractGroup#removeRepetition(String, int) 
991     */
992    public CCR_I16_CLINICAL_HISTORY removeCLINICAL_HISTORY(int rep) throws HL7Exception { 
993       return (CCR_I16_CLINICAL_HISTORY)super.removeRepetition("CLINICAL_HISTORY", rep);
994    }
995
996
997
998
999    /**
1000     * <p>
1001     * Returns
1002     * the first repetition of 
1003     * PATIENT_VISITS (a Group object) - creates it if necessary
1004     * </p>
1005     * 
1006     *
1007     */
1008    public CCR_I16_PATIENT_VISITS getPATIENT_VISITS() { 
1009       return getTyped("PATIENT_VISITS", CCR_I16_PATIENT_VISITS.class);
1010    }
1011
1012
1013    /**
1014     * <p>
1015     * Returns a specific repetition of
1016     * PATIENT_VISITS (a Group object) - creates it if necessary
1017     * </p>
1018     * 
1019     *
1020     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1021     * @throws HL7Exception if the repetition requested is more than one 
1022     *     greater than the number of existing repetitions.
1023     */
1024    public CCR_I16_PATIENT_VISITS getPATIENT_VISITS(int rep) { 
1025       return getTyped("PATIENT_VISITS", rep, CCR_I16_PATIENT_VISITS.class);
1026    }
1027
1028    /** 
1029     * <p>
1030     * Returns the number of existing repetitions of PATIENT_VISITS 
1031     * </p>
1032     * 
1033     */ 
1034    public int getPATIENT_VISITSReps() { 
1035        return getReps("PATIENT_VISITS");
1036    } 
1037
1038    /** 
1039     * <p>
1040     * Returns a non-modifiable List containing all current existing repetitions of PATIENT_VISITS.
1041     * <p>
1042     * <p>
1043     * Note that unlike {@link #getPATIENT_VISITS()}, this method will not create any reps
1044     * if none are already present, so an empty list may be returned.
1045     * </p>
1046     * 
1047     */ 
1048    public java.util.List<CCR_I16_PATIENT_VISITS> getPATIENT_VISITSAll() throws HL7Exception {
1049        return getAllAsList("PATIENT_VISITS", CCR_I16_PATIENT_VISITS.class);
1050    } 
1051
1052    /**
1053     * <p>
1054     * Inserts a specific repetition of PATIENT_VISITS (a Group object)
1055     * </p>
1056     * 
1057     *
1058     * @see AbstractGroup#insertRepetition(Structure, int) 
1059     */
1060    public void insertPATIENT_VISITS(CCR_I16_PATIENT_VISITS structure, int rep) throws HL7Exception { 
1061       super.insertRepetition( "PATIENT_VISITS", structure, rep);
1062    }
1063
1064
1065    /**
1066     * <p>
1067     * Inserts a specific repetition of PATIENT_VISITS (a Group object)
1068     * </p>
1069     * 
1070     *
1071     * @see AbstractGroup#insertRepetition(Structure, int) 
1072     */
1073    public CCR_I16_PATIENT_VISITS insertPATIENT_VISITS(int rep) throws HL7Exception { 
1074       return (CCR_I16_PATIENT_VISITS)super.insertRepetition("PATIENT_VISITS", rep);
1075    }
1076
1077
1078    /**
1079     * <p>
1080     * Removes a specific repetition of PATIENT_VISITS (a Group object)
1081     * </p>
1082     * 
1083     *
1084     * @see AbstractGroup#removeRepetition(String, int) 
1085     */
1086    public CCR_I16_PATIENT_VISITS removePATIENT_VISITS(int rep) throws HL7Exception { 
1087       return (CCR_I16_PATIENT_VISITS)super.removeRepetition("PATIENT_VISITS", rep);
1088    }
1089
1090
1091
1092
1093    /**
1094     * <p>
1095     * Returns
1096     * the first repetition of 
1097     * MEDICATION_HISTORY (a Group object) - creates it if necessary
1098     * </p>
1099     * 
1100     *
1101     */
1102    public CCR_I16_MEDICATION_HISTORY getMEDICATION_HISTORY() { 
1103       return getTyped("MEDICATION_HISTORY", CCR_I16_MEDICATION_HISTORY.class);
1104    }
1105
1106
1107    /**
1108     * <p>
1109     * Returns a specific repetition of
1110     * MEDICATION_HISTORY (a Group object) - creates it if necessary
1111     * </p>
1112     * 
1113     *
1114     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1115     * @throws HL7Exception if the repetition requested is more than one 
1116     *     greater than the number of existing repetitions.
1117     */
1118    public CCR_I16_MEDICATION_HISTORY getMEDICATION_HISTORY(int rep) { 
1119       return getTyped("MEDICATION_HISTORY", rep, CCR_I16_MEDICATION_HISTORY.class);
1120    }
1121
1122    /** 
1123     * <p>
1124     * Returns the number of existing repetitions of MEDICATION_HISTORY 
1125     * </p>
1126     * 
1127     */ 
1128    public int getMEDICATION_HISTORYReps() { 
1129        return getReps("MEDICATION_HISTORY");
1130    } 
1131
1132    /** 
1133     * <p>
1134     * Returns a non-modifiable List containing all current existing repetitions of MEDICATION_HISTORY.
1135     * <p>
1136     * <p>
1137     * Note that unlike {@link #getMEDICATION_HISTORY()}, this method will not create any reps
1138     * if none are already present, so an empty list may be returned.
1139     * </p>
1140     * 
1141     */ 
1142    public java.util.List<CCR_I16_MEDICATION_HISTORY> getMEDICATION_HISTORYAll() throws HL7Exception {
1143        return getAllAsList("MEDICATION_HISTORY", CCR_I16_MEDICATION_HISTORY.class);
1144    } 
1145
1146    /**
1147     * <p>
1148     * Inserts a specific repetition of MEDICATION_HISTORY (a Group object)
1149     * </p>
1150     * 
1151     *
1152     * @see AbstractGroup#insertRepetition(Structure, int) 
1153     */
1154    public void insertMEDICATION_HISTORY(CCR_I16_MEDICATION_HISTORY structure, int rep) throws HL7Exception { 
1155       super.insertRepetition( "MEDICATION_HISTORY", structure, rep);
1156    }
1157
1158
1159    /**
1160     * <p>
1161     * Inserts a specific repetition of MEDICATION_HISTORY (a Group object)
1162     * </p>
1163     * 
1164     *
1165     * @see AbstractGroup#insertRepetition(Structure, int) 
1166     */
1167    public CCR_I16_MEDICATION_HISTORY insertMEDICATION_HISTORY(int rep) throws HL7Exception { 
1168       return (CCR_I16_MEDICATION_HISTORY)super.insertRepetition("MEDICATION_HISTORY", rep);
1169    }
1170
1171
1172    /**
1173     * <p>
1174     * Removes a specific repetition of MEDICATION_HISTORY (a Group object)
1175     * </p>
1176     * 
1177     *
1178     * @see AbstractGroup#removeRepetition(String, int) 
1179     */
1180    public CCR_I16_MEDICATION_HISTORY removeMEDICATION_HISTORY(int rep) throws HL7Exception { 
1181       return (CCR_I16_MEDICATION_HISTORY)super.removeRepetition("MEDICATION_HISTORY", rep);
1182    }
1183
1184
1185
1186
1187    /**
1188     * <p>
1189     * Returns
1190     * the first repetition of 
1191     * PROBLEM (a Group object) - creates it if necessary
1192     * </p>
1193     * 
1194     *
1195     */
1196    public CCR_I16_PROBLEM getPROBLEM() { 
1197       return getTyped("PROBLEM", CCR_I16_PROBLEM.class);
1198    }
1199
1200
1201    /**
1202     * <p>
1203     * Returns a specific repetition of
1204     * PROBLEM (a Group object) - creates it if necessary
1205     * </p>
1206     * 
1207     *
1208     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1209     * @throws HL7Exception if the repetition requested is more than one 
1210     *     greater than the number of existing repetitions.
1211     */
1212    public CCR_I16_PROBLEM getPROBLEM(int rep) { 
1213       return getTyped("PROBLEM", rep, CCR_I16_PROBLEM.class);
1214    }
1215
1216    /** 
1217     * <p>
1218     * Returns the number of existing repetitions of PROBLEM 
1219     * </p>
1220     * 
1221     */ 
1222    public int getPROBLEMReps() { 
1223        return getReps("PROBLEM");
1224    } 
1225
1226    /** 
1227     * <p>
1228     * Returns a non-modifiable List containing all current existing repetitions of PROBLEM.
1229     * <p>
1230     * <p>
1231     * Note that unlike {@link #getPROBLEM()}, this method will not create any reps
1232     * if none are already present, so an empty list may be returned.
1233     * </p>
1234     * 
1235     */ 
1236    public java.util.List<CCR_I16_PROBLEM> getPROBLEMAll() throws HL7Exception {
1237        return getAllAsList("PROBLEM", CCR_I16_PROBLEM.class);
1238    } 
1239
1240    /**
1241     * <p>
1242     * Inserts a specific repetition of PROBLEM (a Group object)
1243     * </p>
1244     * 
1245     *
1246     * @see AbstractGroup#insertRepetition(Structure, int) 
1247     */
1248    public void insertPROBLEM(CCR_I16_PROBLEM structure, int rep) throws HL7Exception { 
1249       super.insertRepetition( "PROBLEM", structure, rep);
1250    }
1251
1252
1253    /**
1254     * <p>
1255     * Inserts a specific repetition of PROBLEM (a Group object)
1256     * </p>
1257     * 
1258     *
1259     * @see AbstractGroup#insertRepetition(Structure, int) 
1260     */
1261    public CCR_I16_PROBLEM insertPROBLEM(int rep) throws HL7Exception { 
1262       return (CCR_I16_PROBLEM)super.insertRepetition("PROBLEM", rep);
1263    }
1264
1265
1266    /**
1267     * <p>
1268     * Removes a specific repetition of PROBLEM (a Group object)
1269     * </p>
1270     * 
1271     *
1272     * @see AbstractGroup#removeRepetition(String, int) 
1273     */
1274    public CCR_I16_PROBLEM removePROBLEM(int rep) throws HL7Exception { 
1275       return (CCR_I16_PROBLEM)super.removeRepetition("PROBLEM", rep);
1276    }
1277
1278
1279
1280
1281    /**
1282     * <p>
1283     * Returns
1284     * the first repetition of 
1285     * GOAL (a Group object) - creates it if necessary
1286     * </p>
1287     * 
1288     *
1289     */
1290    public CCR_I16_GOAL getGOAL() { 
1291       return getTyped("GOAL", CCR_I16_GOAL.class);
1292    }
1293
1294
1295    /**
1296     * <p>
1297     * Returns a specific repetition of
1298     * GOAL (a Group object) - creates it if necessary
1299     * </p>
1300     * 
1301     *
1302     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1303     * @throws HL7Exception if the repetition requested is more than one 
1304     *     greater than the number of existing repetitions.
1305     */
1306    public CCR_I16_GOAL getGOAL(int rep) { 
1307       return getTyped("GOAL", rep, CCR_I16_GOAL.class);
1308    }
1309
1310    /** 
1311     * <p>
1312     * Returns the number of existing repetitions of GOAL 
1313     * </p>
1314     * 
1315     */ 
1316    public int getGOALReps() { 
1317        return getReps("GOAL");
1318    } 
1319
1320    /** 
1321     * <p>
1322     * Returns a non-modifiable List containing all current existing repetitions of GOAL.
1323     * <p>
1324     * <p>
1325     * Note that unlike {@link #getGOAL()}, this method will not create any reps
1326     * if none are already present, so an empty list may be returned.
1327     * </p>
1328     * 
1329     */ 
1330    public java.util.List<CCR_I16_GOAL> getGOALAll() throws HL7Exception {
1331        return getAllAsList("GOAL", CCR_I16_GOAL.class);
1332    } 
1333
1334    /**
1335     * <p>
1336     * Inserts a specific repetition of GOAL (a Group object)
1337     * </p>
1338     * 
1339     *
1340     * @see AbstractGroup#insertRepetition(Structure, int) 
1341     */
1342    public void insertGOAL(CCR_I16_GOAL structure, int rep) throws HL7Exception { 
1343       super.insertRepetition( "GOAL", structure, rep);
1344    }
1345
1346
1347    /**
1348     * <p>
1349     * Inserts a specific repetition of GOAL (a Group object)
1350     * </p>
1351     * 
1352     *
1353     * @see AbstractGroup#insertRepetition(Structure, int) 
1354     */
1355    public CCR_I16_GOAL insertGOAL(int rep) throws HL7Exception { 
1356       return (CCR_I16_GOAL)super.insertRepetition("GOAL", rep);
1357    }
1358
1359
1360    /**
1361     * <p>
1362     * Removes a specific repetition of GOAL (a Group object)
1363     * </p>
1364     * 
1365     *
1366     * @see AbstractGroup#removeRepetition(String, int) 
1367     */
1368    public CCR_I16_GOAL removeGOAL(int rep) throws HL7Exception { 
1369       return (CCR_I16_GOAL)super.removeRepetition("GOAL", rep);
1370    }
1371
1372
1373
1374
1375    /**
1376     * <p>
1377     * Returns
1378     * the first repetition of 
1379     * PATHWAY (a Group object) - creates it if necessary
1380     * </p>
1381     * 
1382     *
1383     */
1384    public CCR_I16_PATHWAY getPATHWAY() { 
1385       return getTyped("PATHWAY", CCR_I16_PATHWAY.class);
1386    }
1387
1388
1389    /**
1390     * <p>
1391     * Returns a specific repetition of
1392     * PATHWAY (a Group object) - creates it if necessary
1393     * </p>
1394     * 
1395     *
1396     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1397     * @throws HL7Exception if the repetition requested is more than one 
1398     *     greater than the number of existing repetitions.
1399     */
1400    public CCR_I16_PATHWAY getPATHWAY(int rep) { 
1401       return getTyped("PATHWAY", rep, CCR_I16_PATHWAY.class);
1402    }
1403
1404    /** 
1405     * <p>
1406     * Returns the number of existing repetitions of PATHWAY 
1407     * </p>
1408     * 
1409     */ 
1410    public int getPATHWAYReps() { 
1411        return getReps("PATHWAY");
1412    } 
1413
1414    /** 
1415     * <p>
1416     * Returns a non-modifiable List containing all current existing repetitions of PATHWAY.
1417     * <p>
1418     * <p>
1419     * Note that unlike {@link #getPATHWAY()}, this method will not create any reps
1420     * if none are already present, so an empty list may be returned.
1421     * </p>
1422     * 
1423     */ 
1424    public java.util.List<CCR_I16_PATHWAY> getPATHWAYAll() throws HL7Exception {
1425        return getAllAsList("PATHWAY", CCR_I16_PATHWAY.class);
1426    } 
1427
1428    /**
1429     * <p>
1430     * Inserts a specific repetition of PATHWAY (a Group object)
1431     * </p>
1432     * 
1433     *
1434     * @see AbstractGroup#insertRepetition(Structure, int) 
1435     */
1436    public void insertPATHWAY(CCR_I16_PATHWAY structure, int rep) throws HL7Exception { 
1437       super.insertRepetition( "PATHWAY", structure, rep);
1438    }
1439
1440
1441    /**
1442     * <p>
1443     * Inserts a specific repetition of PATHWAY (a Group object)
1444     * </p>
1445     * 
1446     *
1447     * @see AbstractGroup#insertRepetition(Structure, int) 
1448     */
1449    public CCR_I16_PATHWAY insertPATHWAY(int rep) throws HL7Exception { 
1450       return (CCR_I16_PATHWAY)super.insertRepetition("PATHWAY", rep);
1451    }
1452
1453
1454    /**
1455     * <p>
1456     * Removes a specific repetition of PATHWAY (a Group object)
1457     * </p>
1458     * 
1459     *
1460     * @see AbstractGroup#removeRepetition(String, int) 
1461     */
1462    public CCR_I16_PATHWAY removePATHWAY(int rep) throws HL7Exception { 
1463       return (CCR_I16_PATHWAY)super.removeRepetition("PATHWAY", rep);
1464    }
1465
1466
1467
1468
1469    /**
1470     * <p>
1471     * Returns
1472     * the first repetition of 
1473     * REL (Clinical Relationship Segment) - creates it if necessary
1474     * </p>
1475     * 
1476     *
1477     */
1478    public REL getREL() { 
1479       return getTyped("REL", REL.class);
1480    }
1481
1482
1483    /**
1484     * <p>
1485     * Returns a specific repetition of
1486     * REL (Clinical Relationship Segment) - creates it if necessary
1487     * </p>
1488     * 
1489     *
1490     * @param rep The repetition index (0-indexed, i.e. the first repetition is at index 0)
1491     * @throws HL7Exception if the repetition requested is more than one 
1492     *     greater than the number of existing repetitions.
1493     */
1494    public REL getREL(int rep) { 
1495       return getTyped("REL", rep, REL.class);
1496    }
1497
1498    /** 
1499     * <p>
1500     * Returns the number of existing repetitions of REL 
1501     * </p>
1502     * 
1503     */ 
1504    public int getRELReps() { 
1505        return getReps("REL");
1506    } 
1507
1508    /** 
1509     * <p>
1510     * Returns a non-modifiable List containing all current existing repetitions of REL.
1511     * <p>
1512     * <p>
1513     * Note that unlike {@link #getREL()}, this method will not create any reps
1514     * if none are already present, so an empty list may be returned.
1515     * </p>
1516     * 
1517     */ 
1518    public java.util.List<REL> getRELAll() throws HL7Exception {
1519        return getAllAsList("REL", REL.class);
1520    } 
1521
1522    /**
1523     * <p>
1524     * Inserts a specific repetition of REL (Clinical Relationship Segment)
1525     * </p>
1526     * 
1527     *
1528     * @see AbstractGroup#insertRepetition(Structure, int) 
1529     */
1530    public void insertREL(REL structure, int rep) throws HL7Exception { 
1531       super.insertRepetition( "REL", structure, rep);
1532    }
1533
1534
1535    /**
1536     * <p>
1537     * Inserts a specific repetition of REL (Clinical Relationship Segment)
1538     * </p>
1539     * 
1540     *
1541     * @see AbstractGroup#insertRepetition(Structure, int) 
1542     */
1543    public REL insertREL(int rep) throws HL7Exception { 
1544       return (REL)super.insertRepetition("REL", rep);
1545    }
1546
1547
1548    /**
1549     * <p>
1550     * Removes a specific repetition of REL (Clinical Relationship Segment)
1551     * </p>
1552     * 
1553     *
1554     * @see AbstractGroup#removeRepetition(String, int) 
1555     */
1556    public REL removeREL(int rep) throws HL7Exception { 
1557       return (REL)super.removeRepetition("REL", rep);
1558    }
1559
1560
1561
1562}
1563