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.v22.segment; 035 036// import ca.uhn.hl7v2.model.v22.group.*; 037import ca.uhn.hl7v2.model.v22.datatype.*; 038import ca.uhn.hl7v2.HL7Exception; 039import ca.uhn.hl7v2.parser.ModelClassFactory; 040import ca.uhn.hl7v2.parser.DefaultModelClassFactory; 041import ca.uhn.hl7v2.model.AbstractMessage; 042import ca.uhn.hl7v2.model.Group; 043import ca.uhn.hl7v2.model.Type; 044import ca.uhn.hl7v2.model.AbstractSegment; 045import ca.uhn.hl7v2.model.Varies; 046 047 048/** 049 *<p>Represents an HL7 URS message segment (UNSOLICITED SELECTION). 050 * This segment has the following fields:</p> 051 * <ul> 052 * <li>URS-1: R/U Where Subject Definition (ST) <b> repeating</b> 053 * <li>URS-2: R/U when data start date / time (TS) <b>optional </b> 054 * <li>URS-3: R/U when data end date / time (TS) <b>optional </b> 055 * <li>URS-4: R/U What User Qualifier (ST) <b>optional repeating</b> 056 * <li>URS-5: R/U Other Results Subject Definition (ST) <b>optional repeating</b> 057 * <li>URS-6: R/U which date / time qualifier (ID) <b>optional repeating</b> 058 * <li>URS-7: R/U which date / time status qualifier (ID) <b>optional repeating</b> 059 * <li>URS-8: R/U date / time selection qualifier (ID) <b>optional repeating</b> 060 * </ul> 061 */ 062@SuppressWarnings("unused") 063public class URS extends AbstractSegment { 064 065 /** 066 * Creates a new URS segment 067 */ 068 public URS(Group parent, ModelClassFactory factory) { 069 super(parent, factory); 070 init(factory); 071 } 072 073 private void init(ModelClassFactory factory) { 074 try { 075 this.add(ST.class, true, 0, 20, new Object[]{ getMessage() }, "R/U Where Subject Definition"); 076 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "R/U when data start date / time"); 077 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "R/U when data end date / time"); 078 this.add(ST.class, false, 0, 20, new Object[]{ getMessage() }, "R/U What User Qualifier"); 079 this.add(ST.class, false, 0, 20, new Object[]{ getMessage() }, "R/U Other Results Subject Definition"); 080 this.add(ID.class, false, 0, 12, new Object[]{ getMessage(), new Integer(156) }, "R/U which date / time qualifier"); 081 this.add(ID.class, false, 0, 12, new Object[]{ getMessage(), new Integer(157) }, "R/U which date / time status qualifier"); 082 this.add(ID.class, false, 0, 12, new Object[]{ getMessage(), new Integer(158) }, "R/U date / time selection qualifier"); 083 } catch(HL7Exception e) { 084 log.error("Unexpected error creating URS - this is probably a bug in the source code generator.", e); 085 } 086 } 087 088 089 /** 090 * Returns all repetitions of R/U Where Subject Definition (URS-1). 091 */ 092 public ST[] getRUWhereSubjectDefinition() { 093 ST[] retVal = this.getTypedField(1, new ST[0]); 094 return retVal; 095 } 096 097 098 /** 099 * Returns all repetitions of R/U Where Subject Definition (URS-1). 100 */ 101 public ST[] getUrs1_RUWhereSubjectDefinition() { 102 ST[] retVal = this.getTypedField(1, new ST[0]); 103 return retVal; 104 } 105 106 107 /** 108 * Returns a count of the current number of repetitions of R/U Where Subject Definition (URS-1). 109 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 110 * it will return zero. 111 */ 112 public int getRUWhereSubjectDefinitionReps() { 113 return this.getReps(1); 114 } 115 116 117 /** 118 * Returns a specific repetition of 119 * URS-1: "R/U Where Subject Definition" - creates it if necessary 120 * 121 * @param rep The repetition index (0-indexed) 122 */ 123 public ST getRUWhereSubjectDefinition(int rep) { 124 ST retVal = this.getTypedField(1, rep); 125 return retVal; 126 } 127 128 /** 129 * Returns a specific repetition of 130 * URS-1: "R/U Where Subject Definition" - creates it if necessary 131 * 132 * @param rep The repetition index (0-indexed) 133 */ 134 public ST getUrs1_RUWhereSubjectDefinition(int rep) { 135 ST retVal = this.getTypedField(1, rep); 136 return retVal; 137 } 138 139 /** 140 * Returns a count of the current number of repetitions of R/U Where Subject Definition (URS-1). 141 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 142 * it will return zero. 143 */ 144 public int getUrs1_RUWhereSubjectDefinitionReps() { 145 return this.getReps(1); 146 } 147 148 149 /** 150 * Inserts a repetition of 151 * URS-1: "R/U Where Subject Definition" at a specific index 152 * 153 * @param rep The repetition index (0-indexed) 154 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 155 */ 156 public ST insertRUWhereSubjectDefinition(int rep) throws HL7Exception { 157 return (ST) super.insertRepetition(1, rep); 158 } 159 160 161 /** 162 * Inserts a repetition of 163 * URS-1: "R/U Where Subject Definition" at a specific index 164 * 165 * @param rep The repetition index (0-indexed) 166 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 167 */ 168 public ST insertUrs1_RUWhereSubjectDefinition(int rep) throws HL7Exception { 169 return (ST) super.insertRepetition(1, rep); 170 } 171 172 173 /** 174 * Removes a repetition of 175 * URS-1: "R/U Where Subject Definition" at a specific index 176 * 177 * @param rep The repetition index (0-indexed) 178 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 179 */ 180 public ST removeRUWhereSubjectDefinition(int rep) throws HL7Exception { 181 return (ST) super.removeRepetition(1, rep); 182 } 183 184 185 /** 186 * Removes a repetition of 187 * URS-1: "R/U Where Subject Definition" at a specific index 188 * 189 * @param rep The repetition index (0-indexed) 190 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 191 */ 192 public ST removeUrs1_RUWhereSubjectDefinition(int rep) throws HL7Exception { 193 return (ST) super.removeRepetition(1, rep); 194 } 195 196 197 198 199 /** 200 * Returns 201 * URS-2: "R/U when data start date / time" - creates it if necessary 202 */ 203 public TS getRUWhenDataStartDateTime() { 204 TS retVal = this.getTypedField(2, 0); 205 return retVal; 206 } 207 208 /** 209 * Returns 210 * URS-2: "R/U when data start date / time" - creates it if necessary 211 */ 212 public TS getUrs2_RUWhenDataStartDateTime() { 213 TS retVal = this.getTypedField(2, 0); 214 return retVal; 215 } 216 217 218 219 /** 220 * Returns 221 * URS-3: "R/U when data end date / time" - creates it if necessary 222 */ 223 public TS getRUWhenDataEndDateTime() { 224 TS retVal = this.getTypedField(3, 0); 225 return retVal; 226 } 227 228 /** 229 * Returns 230 * URS-3: "R/U when data end date / time" - creates it if necessary 231 */ 232 public TS getUrs3_RUWhenDataEndDateTime() { 233 TS retVal = this.getTypedField(3, 0); 234 return retVal; 235 } 236 237 238 /** 239 * Returns all repetitions of R/U What User Qualifier (URS-4). 240 */ 241 public ST[] getRUWhatUserQualifier() { 242 ST[] retVal = this.getTypedField(4, new ST[0]); 243 return retVal; 244 } 245 246 247 /** 248 * Returns all repetitions of R/U What User Qualifier (URS-4). 249 */ 250 public ST[] getUrs4_RUWhatUserQualifier() { 251 ST[] retVal = this.getTypedField(4, new ST[0]); 252 return retVal; 253 } 254 255 256 /** 257 * Returns a count of the current number of repetitions of R/U What User Qualifier (URS-4). 258 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 259 * it will return zero. 260 */ 261 public int getRUWhatUserQualifierReps() { 262 return this.getReps(4); 263 } 264 265 266 /** 267 * Returns a specific repetition of 268 * URS-4: "R/U What User Qualifier" - creates it if necessary 269 * 270 * @param rep The repetition index (0-indexed) 271 */ 272 public ST getRUWhatUserQualifier(int rep) { 273 ST retVal = this.getTypedField(4, rep); 274 return retVal; 275 } 276 277 /** 278 * Returns a specific repetition of 279 * URS-4: "R/U What User Qualifier" - creates it if necessary 280 * 281 * @param rep The repetition index (0-indexed) 282 */ 283 public ST getUrs4_RUWhatUserQualifier(int rep) { 284 ST retVal = this.getTypedField(4, rep); 285 return retVal; 286 } 287 288 /** 289 * Returns a count of the current number of repetitions of R/U What User Qualifier (URS-4). 290 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 291 * it will return zero. 292 */ 293 public int getUrs4_RUWhatUserQualifierReps() { 294 return this.getReps(4); 295 } 296 297 298 /** 299 * Inserts a repetition of 300 * URS-4: "R/U What User Qualifier" at a specific index 301 * 302 * @param rep The repetition index (0-indexed) 303 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 304 */ 305 public ST insertRUWhatUserQualifier(int rep) throws HL7Exception { 306 return (ST) super.insertRepetition(4, rep); 307 } 308 309 310 /** 311 * Inserts a repetition of 312 * URS-4: "R/U What User Qualifier" at a specific index 313 * 314 * @param rep The repetition index (0-indexed) 315 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 316 */ 317 public ST insertUrs4_RUWhatUserQualifier(int rep) throws HL7Exception { 318 return (ST) super.insertRepetition(4, rep); 319 } 320 321 322 /** 323 * Removes a repetition of 324 * URS-4: "R/U What User Qualifier" at a specific index 325 * 326 * @param rep The repetition index (0-indexed) 327 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 328 */ 329 public ST removeRUWhatUserQualifier(int rep) throws HL7Exception { 330 return (ST) super.removeRepetition(4, rep); 331 } 332 333 334 /** 335 * Removes a repetition of 336 * URS-4: "R/U What User Qualifier" at a specific index 337 * 338 * @param rep The repetition index (0-indexed) 339 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 340 */ 341 public ST removeUrs4_RUWhatUserQualifier(int rep) throws HL7Exception { 342 return (ST) super.removeRepetition(4, rep); 343 } 344 345 346 347 /** 348 * Returns all repetitions of R/U Other Results Subject Definition (URS-5). 349 */ 350 public ST[] getRUOtherResultsSubjectDefinition() { 351 ST[] retVal = this.getTypedField(5, new ST[0]); 352 return retVal; 353 } 354 355 356 /** 357 * Returns all repetitions of R/U Other Results Subject Definition (URS-5). 358 */ 359 public ST[] getUrs5_RUOtherResultsSubjectDefinition() { 360 ST[] retVal = this.getTypedField(5, new ST[0]); 361 return retVal; 362 } 363 364 365 /** 366 * Returns a count of the current number of repetitions of R/U Other Results Subject Definition (URS-5). 367 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 368 * it will return zero. 369 */ 370 public int getRUOtherResultsSubjectDefinitionReps() { 371 return this.getReps(5); 372 } 373 374 375 /** 376 * Returns a specific repetition of 377 * URS-5: "R/U Other Results Subject Definition" - creates it if necessary 378 * 379 * @param rep The repetition index (0-indexed) 380 */ 381 public ST getRUOtherResultsSubjectDefinition(int rep) { 382 ST retVal = this.getTypedField(5, rep); 383 return retVal; 384 } 385 386 /** 387 * Returns a specific repetition of 388 * URS-5: "R/U Other Results Subject Definition" - creates it if necessary 389 * 390 * @param rep The repetition index (0-indexed) 391 */ 392 public ST getUrs5_RUOtherResultsSubjectDefinition(int rep) { 393 ST retVal = this.getTypedField(5, rep); 394 return retVal; 395 } 396 397 /** 398 * Returns a count of the current number of repetitions of R/U Other Results Subject Definition (URS-5). 399 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 400 * it will return zero. 401 */ 402 public int getUrs5_RUOtherResultsSubjectDefinitionReps() { 403 return this.getReps(5); 404 } 405 406 407 /** 408 * Inserts a repetition of 409 * URS-5: "R/U Other Results Subject Definition" 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 ST insertRUOtherResultsSubjectDefinition(int rep) throws HL7Exception { 415 return (ST) super.insertRepetition(5, rep); 416 } 417 418 419 /** 420 * Inserts a repetition of 421 * URS-5: "R/U Other Results Subject Definition" at a specific index 422 * 423 * @param rep The repetition index (0-indexed) 424 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 425 */ 426 public ST insertUrs5_RUOtherResultsSubjectDefinition(int rep) throws HL7Exception { 427 return (ST) super.insertRepetition(5, rep); 428 } 429 430 431 /** 432 * Removes a repetition of 433 * URS-5: "R/U Other Results Subject Definition" at a specific index 434 * 435 * @param rep The repetition index (0-indexed) 436 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 437 */ 438 public ST removeRUOtherResultsSubjectDefinition(int rep) throws HL7Exception { 439 return (ST) super.removeRepetition(5, rep); 440 } 441 442 443 /** 444 * Removes a repetition of 445 * URS-5: "R/U Other Results Subject Definition" at a specific index 446 * 447 * @param rep The repetition index (0-indexed) 448 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 449 */ 450 public ST removeUrs5_RUOtherResultsSubjectDefinition(int rep) throws HL7Exception { 451 return (ST) super.removeRepetition(5, rep); 452 } 453 454 455 456 /** 457 * Returns all repetitions of R/U which date / time qualifier (URS-6). 458 */ 459 public ID[] getRUWhichDateTimeQualifier() { 460 ID[] retVal = this.getTypedField(6, new ID[0]); 461 return retVal; 462 } 463 464 465 /** 466 * Returns all repetitions of R/U which date / time qualifier (URS-6). 467 */ 468 public ID[] getUrs6_RUWhichDateTimeQualifier() { 469 ID[] retVal = this.getTypedField(6, new ID[0]); 470 return retVal; 471 } 472 473 474 /** 475 * Returns a count of the current number of repetitions of R/U which date / time qualifier (URS-6). 476 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 477 * it will return zero. 478 */ 479 public int getRUWhichDateTimeQualifierReps() { 480 return this.getReps(6); 481 } 482 483 484 /** 485 * Returns a specific repetition of 486 * URS-6: "R/U which date / time qualifier" - creates it if necessary 487 * 488 * @param rep The repetition index (0-indexed) 489 */ 490 public ID getRUWhichDateTimeQualifier(int rep) { 491 ID retVal = this.getTypedField(6, rep); 492 return retVal; 493 } 494 495 /** 496 * Returns a specific repetition of 497 * URS-6: "R/U which date / time qualifier" - creates it if necessary 498 * 499 * @param rep The repetition index (0-indexed) 500 */ 501 public ID getUrs6_RUWhichDateTimeQualifier(int rep) { 502 ID retVal = this.getTypedField(6, rep); 503 return retVal; 504 } 505 506 /** 507 * Returns a count of the current number of repetitions of R/U which date / time qualifier (URS-6). 508 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 509 * it will return zero. 510 */ 511 public int getUrs6_RUWhichDateTimeQualifierReps() { 512 return this.getReps(6); 513 } 514 515 516 /** 517 * Inserts a repetition of 518 * URS-6: "R/U which date / time qualifier" at a specific index 519 * 520 * @param rep The repetition index (0-indexed) 521 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 522 */ 523 public ID insertRUWhichDateTimeQualifier(int rep) throws HL7Exception { 524 return (ID) super.insertRepetition(6, rep); 525 } 526 527 528 /** 529 * Inserts a repetition of 530 * URS-6: "R/U which date / time qualifier" at a specific index 531 * 532 * @param rep The repetition index (0-indexed) 533 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 534 */ 535 public ID insertUrs6_RUWhichDateTimeQualifier(int rep) throws HL7Exception { 536 return (ID) super.insertRepetition(6, rep); 537 } 538 539 540 /** 541 * Removes a repetition of 542 * URS-6: "R/U which date / time qualifier" at a specific index 543 * 544 * @param rep The repetition index (0-indexed) 545 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 546 */ 547 public ID removeRUWhichDateTimeQualifier(int rep) throws HL7Exception { 548 return (ID) super.removeRepetition(6, rep); 549 } 550 551 552 /** 553 * Removes a repetition of 554 * URS-6: "R/U which date / time qualifier" at a specific index 555 * 556 * @param rep The repetition index (0-indexed) 557 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 558 */ 559 public ID removeUrs6_RUWhichDateTimeQualifier(int rep) throws HL7Exception { 560 return (ID) super.removeRepetition(6, rep); 561 } 562 563 564 565 /** 566 * Returns all repetitions of R/U which date / time status qualifier (URS-7). 567 */ 568 public ID[] getRUWhichDateTimeStatusQualifier() { 569 ID[] retVal = this.getTypedField(7, new ID[0]); 570 return retVal; 571 } 572 573 574 /** 575 * Returns all repetitions of R/U which date / time status qualifier (URS-7). 576 */ 577 public ID[] getUrs7_RUWhichDateTimeStatusQualifier() { 578 ID[] retVal = this.getTypedField(7, new ID[0]); 579 return retVal; 580 } 581 582 583 /** 584 * Returns a count of the current number of repetitions of R/U which date / time status qualifier (URS-7). 585 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 586 * it will return zero. 587 */ 588 public int getRUWhichDateTimeStatusQualifierReps() { 589 return this.getReps(7); 590 } 591 592 593 /** 594 * Returns a specific repetition of 595 * URS-7: "R/U which date / time status qualifier" - creates it if necessary 596 * 597 * @param rep The repetition index (0-indexed) 598 */ 599 public ID getRUWhichDateTimeStatusQualifier(int rep) { 600 ID retVal = this.getTypedField(7, rep); 601 return retVal; 602 } 603 604 /** 605 * Returns a specific repetition of 606 * URS-7: "R/U which date / time status qualifier" - creates it if necessary 607 * 608 * @param rep The repetition index (0-indexed) 609 */ 610 public ID getUrs7_RUWhichDateTimeStatusQualifier(int rep) { 611 ID retVal = this.getTypedField(7, rep); 612 return retVal; 613 } 614 615 /** 616 * Returns a count of the current number of repetitions of R/U which date / time status qualifier (URS-7). 617 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 618 * it will return zero. 619 */ 620 public int getUrs7_RUWhichDateTimeStatusQualifierReps() { 621 return this.getReps(7); 622 } 623 624 625 /** 626 * Inserts a repetition of 627 * URS-7: "R/U which date / time status qualifier" at a specific index 628 * 629 * @param rep The repetition index (0-indexed) 630 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 631 */ 632 public ID insertRUWhichDateTimeStatusQualifier(int rep) throws HL7Exception { 633 return (ID) super.insertRepetition(7, rep); 634 } 635 636 637 /** 638 * Inserts a repetition of 639 * URS-7: "R/U which date / time status qualifier" at a specific index 640 * 641 * @param rep The repetition index (0-indexed) 642 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 643 */ 644 public ID insertUrs7_RUWhichDateTimeStatusQualifier(int rep) throws HL7Exception { 645 return (ID) super.insertRepetition(7, rep); 646 } 647 648 649 /** 650 * Removes a repetition of 651 * URS-7: "R/U which date / time status qualifier" at a specific index 652 * 653 * @param rep The repetition index (0-indexed) 654 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 655 */ 656 public ID removeRUWhichDateTimeStatusQualifier(int rep) throws HL7Exception { 657 return (ID) super.removeRepetition(7, rep); 658 } 659 660 661 /** 662 * Removes a repetition of 663 * URS-7: "R/U which date / time status qualifier" at a specific index 664 * 665 * @param rep The repetition index (0-indexed) 666 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 667 */ 668 public ID removeUrs7_RUWhichDateTimeStatusQualifier(int rep) throws HL7Exception { 669 return (ID) super.removeRepetition(7, rep); 670 } 671 672 673 674 /** 675 * Returns all repetitions of R/U date / time selection qualifier (URS-8). 676 */ 677 public ID[] getRUDateTimeSelectionQualifier() { 678 ID[] retVal = this.getTypedField(8, new ID[0]); 679 return retVal; 680 } 681 682 683 /** 684 * Returns all repetitions of R/U date / time selection qualifier (URS-8). 685 */ 686 public ID[] getUrs8_RUDateTimeSelectionQualifier() { 687 ID[] retVal = this.getTypedField(8, new ID[0]); 688 return retVal; 689 } 690 691 692 /** 693 * Returns a count of the current number of repetitions of R/U date / time selection qualifier (URS-8). 694 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 695 * it will return zero. 696 */ 697 public int getRUDateTimeSelectionQualifierReps() { 698 return this.getReps(8); 699 } 700 701 702 /** 703 * Returns a specific repetition of 704 * URS-8: "R/U date / time selection qualifier" - creates it if necessary 705 * 706 * @param rep The repetition index (0-indexed) 707 */ 708 public ID getRUDateTimeSelectionQualifier(int rep) { 709 ID retVal = this.getTypedField(8, rep); 710 return retVal; 711 } 712 713 /** 714 * Returns a specific repetition of 715 * URS-8: "R/U date / time selection qualifier" - creates it if necessary 716 * 717 * @param rep The repetition index (0-indexed) 718 */ 719 public ID getUrs8_RUDateTimeSelectionQualifier(int rep) { 720 ID retVal = this.getTypedField(8, rep); 721 return retVal; 722 } 723 724 /** 725 * Returns a count of the current number of repetitions of R/U date / time selection qualifier (URS-8). 726 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 727 * it will return zero. 728 */ 729 public int getUrs8_RUDateTimeSelectionQualifierReps() { 730 return this.getReps(8); 731 } 732 733 734 /** 735 * Inserts a repetition of 736 * URS-8: "R/U date / time selection qualifier" at a specific index 737 * 738 * @param rep The repetition index (0-indexed) 739 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 740 */ 741 public ID insertRUDateTimeSelectionQualifier(int rep) throws HL7Exception { 742 return (ID) super.insertRepetition(8, rep); 743 } 744 745 746 /** 747 * Inserts a repetition of 748 * URS-8: "R/U date / time selection qualifier" at a specific index 749 * 750 * @param rep The repetition index (0-indexed) 751 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 752 */ 753 public ID insertUrs8_RUDateTimeSelectionQualifier(int rep) throws HL7Exception { 754 return (ID) super.insertRepetition(8, rep); 755 } 756 757 758 /** 759 * Removes a repetition of 760 * URS-8: "R/U date / time selection qualifier" at a specific index 761 * 762 * @param rep The repetition index (0-indexed) 763 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 764 */ 765 public ID removeRUDateTimeSelectionQualifier(int rep) throws HL7Exception { 766 return (ID) super.removeRepetition(8, rep); 767 } 768 769 770 /** 771 * Removes a repetition of 772 * URS-8: "R/U date / time selection qualifier" at a specific index 773 * 774 * @param rep The repetition index (0-indexed) 775 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 776 */ 777 public ID removeUrs8_RUDateTimeSelectionQualifier(int rep) throws HL7Exception { 778 return (ID) super.removeRepetition(8, rep); 779 } 780 781 782 783 784 785 786 /** {@inheritDoc} */ 787 protected Type createNewTypeWithoutReflection(int field) { 788 switch (field) { 789 case 0: return new ST(getMessage()); 790 case 1: return new TS(getMessage()); 791 case 2: return new TS(getMessage()); 792 case 3: return new ST(getMessage()); 793 case 4: return new ST(getMessage()); 794 case 5: return new ID(getMessage(), new Integer( 156 )); 795 case 6: return new ID(getMessage(), new Integer( 157 )); 796 case 7: return new ID(getMessage(), new Integer( 158 )); 797 default: return null; 798 } 799 } 800 801 802} 803