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.v231.segment; 035 036// import ca.uhn.hl7v2.model.v231.group.*; 037import ca.uhn.hl7v2.model.v231.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 *<p>Represents an HL7 CSR message segment (CSR - clinical study registration segment). 049 * This segment has the following fields:</p> 050 * <ul> 051 * <li>CSR-1: Sponsor Study ID (EI) <b> </b> 052 * <li>CSR-2: Alternate Study ID (EI) <b>optional </b> 053 * <li>CSR-3: Institution Registering the Patient (CE) <b>optional </b> 054 * <li>CSR-4: Sponsor Patient ID (CX) <b> </b> 055 * <li>CSR-5: Alternate Patient ID - CSR (CX) <b>optional </b> 056 * <li>CSR-6: Date/Time Of Patient Study Registration (TS) <b> </b> 057 * <li>CSR-7: Person Performing Study Registration (XCN) <b>optional repeating</b> 058 * <li>CSR-8: Study Authorizing Provider (XCN) <b> repeating</b> 059 * <li>CSR-9: Date/time Patient Study Consent Signed (TS) <b>optional </b> 060 * <li>CSR-10: Patient Study Eligibility Status (CE) <b>optional </b> 061 * <li>CSR-11: Study Randomization Date/time (TS) <b>optional repeating</b> 062 * <li>CSR-12: Randomized Study Arm (CE) <b>optional repeating</b> 063 * <li>CSR-13: Stratum for Study Randomization (CE) <b>optional repeating</b> 064 * <li>CSR-14: Patient Evaluability Status (CE) <b>optional </b> 065 * <li>CSR-15: Date/time Ended Study (TS) <b>optional </b> 066 * <li>CSR-16: Reason Ended Study (CE) <b>optional </b> 067 * </ul> 068 */ 069@SuppressWarnings("unused") 070public class CSR extends AbstractSegment { 071 072 /** 073 * Creates a new CSR segment 074 */ 075 public CSR(Group parent, ModelClassFactory factory) { 076 super(parent, factory); 077 init(factory); 078 } 079 080 private void init(ModelClassFactory factory) { 081 try { 082 this.add(EI.class, true, 1, 60, new Object[]{ getMessage() }, "Sponsor Study ID"); 083 this.add(EI.class, false, 1, 60, new Object[]{ getMessage() }, "Alternate Study ID"); 084 this.add(CE.class, false, 1, 60, new Object[]{ getMessage() }, "Institution Registering the Patient"); 085 this.add(CX.class, true, 1, 30, new Object[]{ getMessage() }, "Sponsor Patient ID"); 086 this.add(CX.class, false, 1, 30, new Object[]{ getMessage() }, "Alternate Patient ID - CSR"); 087 this.add(TS.class, true, 1, 26, new Object[]{ getMessage() }, "Date/Time Of Patient Study Registration"); 088 this.add(XCN.class, false, 0, 60, new Object[]{ getMessage() }, "Person Performing Study Registration"); 089 this.add(XCN.class, true, 0, 60, new Object[]{ getMessage() }, "Study Authorizing Provider"); 090 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "Date/time Patient Study Consent Signed"); 091 this.add(CE.class, false, 1, 60, new Object[]{ getMessage() }, "Patient Study Eligibility Status"); 092 this.add(TS.class, false, 3, 26, new Object[]{ getMessage() }, "Study Randomization Date/time"); 093 this.add(CE.class, false, 3, 200, new Object[]{ getMessage() }, "Randomized Study Arm"); 094 this.add(CE.class, false, 3, 200, new Object[]{ getMessage() }, "Stratum for Study Randomization"); 095 this.add(CE.class, false, 1, 60, new Object[]{ getMessage() }, "Patient Evaluability Status"); 096 this.add(TS.class, false, 1, 26, new Object[]{ getMessage() }, "Date/time Ended Study"); 097 this.add(CE.class, false, 1, 60, new Object[]{ getMessage() }, "Reason Ended Study"); 098 } catch(HL7Exception e) { 099 log.error("Unexpected error creating CSR - this is probably a bug in the source code generator.", e); 100 } 101 } 102 103 104 105 /** 106 * Returns 107 * CSR-1: "Sponsor Study ID" - creates it if necessary 108 */ 109 public EI getSponsorStudyID() { 110 EI retVal = this.getTypedField(1, 0); 111 return retVal; 112 } 113 114 /** 115 * Returns 116 * CSR-1: "Sponsor Study ID" - creates it if necessary 117 */ 118 public EI getCsr1_SponsorStudyID() { 119 EI retVal = this.getTypedField(1, 0); 120 return retVal; 121 } 122 123 124 125 /** 126 * Returns 127 * CSR-2: "Alternate Study ID" - creates it if necessary 128 */ 129 public EI getAlternateStudyID() { 130 EI retVal = this.getTypedField(2, 0); 131 return retVal; 132 } 133 134 /** 135 * Returns 136 * CSR-2: "Alternate Study ID" - creates it if necessary 137 */ 138 public EI getCsr2_AlternateStudyID() { 139 EI retVal = this.getTypedField(2, 0); 140 return retVal; 141 } 142 143 144 145 /** 146 * Returns 147 * CSR-3: "Institution Registering the Patient" - creates it if necessary 148 */ 149 public CE getInstitutionRegisteringThePatient() { 150 CE retVal = this.getTypedField(3, 0); 151 return retVal; 152 } 153 154 /** 155 * Returns 156 * CSR-3: "Institution Registering the Patient" - creates it if necessary 157 */ 158 public CE getCsr3_InstitutionRegisteringThePatient() { 159 CE retVal = this.getTypedField(3, 0); 160 return retVal; 161 } 162 163 164 165 /** 166 * Returns 167 * CSR-4: "Sponsor Patient ID" - creates it if necessary 168 */ 169 public CX getSponsorPatientID() { 170 CX retVal = this.getTypedField(4, 0); 171 return retVal; 172 } 173 174 /** 175 * Returns 176 * CSR-4: "Sponsor Patient ID" - creates it if necessary 177 */ 178 public CX getCsr4_SponsorPatientID() { 179 CX retVal = this.getTypedField(4, 0); 180 return retVal; 181 } 182 183 184 185 /** 186 * Returns 187 * CSR-5: "Alternate Patient ID - CSR" - creates it if necessary 188 */ 189 public CX getAlternatePatientIDCSR() { 190 CX retVal = this.getTypedField(5, 0); 191 return retVal; 192 } 193 194 /** 195 * Returns 196 * CSR-5: "Alternate Patient ID - CSR" - creates it if necessary 197 */ 198 public CX getCsr5_AlternatePatientIDCSR() { 199 CX retVal = this.getTypedField(5, 0); 200 return retVal; 201 } 202 203 204 205 /** 206 * Returns 207 * CSR-6: "Date/Time Of Patient Study Registration" - creates it if necessary 208 */ 209 public TS getDateTimeOfPatientStudyRegistration() { 210 TS retVal = this.getTypedField(6, 0); 211 return retVal; 212 } 213 214 /** 215 * Returns 216 * CSR-6: "Date/Time Of Patient Study Registration" - creates it if necessary 217 */ 218 public TS getCsr6_DateTimeOfPatientStudyRegistration() { 219 TS retVal = this.getTypedField(6, 0); 220 return retVal; 221 } 222 223 224 /** 225 * Returns all repetitions of Person Performing Study Registration (CSR-7). 226 */ 227 public XCN[] getPersonPerformingStudyRegistration() { 228 XCN[] retVal = this.getTypedField(7, new XCN[0]); 229 return retVal; 230 } 231 232 233 /** 234 * Returns all repetitions of Person Performing Study Registration (CSR-7). 235 */ 236 public XCN[] getCsr7_PersonPerformingStudyRegistration() { 237 XCN[] retVal = this.getTypedField(7, new XCN[0]); 238 return retVal; 239 } 240 241 242 /** 243 * Returns a count of the current number of repetitions of Person Performing Study Registration (CSR-7). 244 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 245 * it will return zero. 246 */ 247 public int getPersonPerformingStudyRegistrationReps() { 248 return this.getReps(7); 249 } 250 251 252 /** 253 * Returns a specific repetition of 254 * CSR-7: "Person Performing Study Registration" - creates it if necessary 255 * 256 * @param rep The repetition index (0-indexed) 257 */ 258 public XCN getPersonPerformingStudyRegistration(int rep) { 259 XCN retVal = this.getTypedField(7, rep); 260 return retVal; 261 } 262 263 /** 264 * Returns a specific repetition of 265 * CSR-7: "Person Performing Study Registration" - creates it if necessary 266 * 267 * @param rep The repetition index (0-indexed) 268 */ 269 public XCN getCsr7_PersonPerformingStudyRegistration(int rep) { 270 XCN retVal = this.getTypedField(7, rep); 271 return retVal; 272 } 273 274 /** 275 * Returns a count of the current number of repetitions of Person Performing Study Registration (CSR-7). 276 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 277 * it will return zero. 278 */ 279 public int getCsr7_PersonPerformingStudyRegistrationReps() { 280 return this.getReps(7); 281 } 282 283 284 /** 285 * Inserts a repetition of 286 * CSR-7: "Person Performing Study Registration" at a specific index 287 * 288 * @param rep The repetition index (0-indexed) 289 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 290 */ 291 public XCN insertPersonPerformingStudyRegistration(int rep) throws HL7Exception { 292 return (XCN) super.insertRepetition(7, rep); 293 } 294 295 296 /** 297 * Inserts a repetition of 298 * CSR-7: "Person Performing Study Registration" at a specific index 299 * 300 * @param rep The repetition index (0-indexed) 301 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 302 */ 303 public XCN insertCsr7_PersonPerformingStudyRegistration(int rep) throws HL7Exception { 304 return (XCN) super.insertRepetition(7, rep); 305 } 306 307 308 /** 309 * Removes a repetition of 310 * CSR-7: "Person Performing Study Registration" at a specific index 311 * 312 * @param rep The repetition index (0-indexed) 313 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 314 */ 315 public XCN removePersonPerformingStudyRegistration(int rep) throws HL7Exception { 316 return (XCN) super.removeRepetition(7, rep); 317 } 318 319 320 /** 321 * Removes a repetition of 322 * CSR-7: "Person Performing Study Registration" at a specific index 323 * 324 * @param rep The repetition index (0-indexed) 325 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 326 */ 327 public XCN removeCsr7_PersonPerformingStudyRegistration(int rep) throws HL7Exception { 328 return (XCN) super.removeRepetition(7, rep); 329 } 330 331 332 333 /** 334 * Returns all repetitions of Study Authorizing Provider (CSR-8). 335 */ 336 public XCN[] getStudyAuthorizingProvider() { 337 XCN[] retVal = this.getTypedField(8, new XCN[0]); 338 return retVal; 339 } 340 341 342 /** 343 * Returns all repetitions of Study Authorizing Provider (CSR-8). 344 */ 345 public XCN[] getCsr8_StudyAuthorizingProvider() { 346 XCN[] retVal = this.getTypedField(8, new XCN[0]); 347 return retVal; 348 } 349 350 351 /** 352 * Returns a count of the current number of repetitions of Study Authorizing Provider (CSR-8). 353 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 354 * it will return zero. 355 */ 356 public int getStudyAuthorizingProviderReps() { 357 return this.getReps(8); 358 } 359 360 361 /** 362 * Returns a specific repetition of 363 * CSR-8: "Study Authorizing Provider" - creates it if necessary 364 * 365 * @param rep The repetition index (0-indexed) 366 */ 367 public XCN getStudyAuthorizingProvider(int rep) { 368 XCN retVal = this.getTypedField(8, rep); 369 return retVal; 370 } 371 372 /** 373 * Returns a specific repetition of 374 * CSR-8: "Study Authorizing Provider" - creates it if necessary 375 * 376 * @param rep The repetition index (0-indexed) 377 */ 378 public XCN getCsr8_StudyAuthorizingProvider(int rep) { 379 XCN retVal = this.getTypedField(8, rep); 380 return retVal; 381 } 382 383 /** 384 * Returns a count of the current number of repetitions of Study Authorizing Provider (CSR-8). 385 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 386 * it will return zero. 387 */ 388 public int getCsr8_StudyAuthorizingProviderReps() { 389 return this.getReps(8); 390 } 391 392 393 /** 394 * Inserts a repetition of 395 * CSR-8: "Study Authorizing Provider" at a specific index 396 * 397 * @param rep The repetition index (0-indexed) 398 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 399 */ 400 public XCN insertStudyAuthorizingProvider(int rep) throws HL7Exception { 401 return (XCN) super.insertRepetition(8, rep); 402 } 403 404 405 /** 406 * Inserts a repetition of 407 * CSR-8: "Study Authorizing Provider" at a specific index 408 * 409 * @param rep The repetition index (0-indexed) 410 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 411 */ 412 public XCN insertCsr8_StudyAuthorizingProvider(int rep) throws HL7Exception { 413 return (XCN) super.insertRepetition(8, rep); 414 } 415 416 417 /** 418 * Removes a repetition of 419 * CSR-8: "Study Authorizing Provider" at a specific index 420 * 421 * @param rep The repetition index (0-indexed) 422 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 423 */ 424 public XCN removeStudyAuthorizingProvider(int rep) throws HL7Exception { 425 return (XCN) super.removeRepetition(8, rep); 426 } 427 428 429 /** 430 * Removes a repetition of 431 * CSR-8: "Study Authorizing Provider" at a specific index 432 * 433 * @param rep The repetition index (0-indexed) 434 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 435 */ 436 public XCN removeCsr8_StudyAuthorizingProvider(int rep) throws HL7Exception { 437 return (XCN) super.removeRepetition(8, rep); 438 } 439 440 441 442 443 /** 444 * Returns 445 * CSR-9: "Date/time Patient Study Consent Signed" - creates it if necessary 446 */ 447 public TS getDateTimePatientStudyConsentSigned() { 448 TS retVal = this.getTypedField(9, 0); 449 return retVal; 450 } 451 452 /** 453 * Returns 454 * CSR-9: "Date/time Patient Study Consent Signed" - creates it if necessary 455 */ 456 public TS getCsr9_DateTimePatientStudyConsentSigned() { 457 TS retVal = this.getTypedField(9, 0); 458 return retVal; 459 } 460 461 462 463 /** 464 * Returns 465 * CSR-10: "Patient Study Eligibility Status" - creates it if necessary 466 */ 467 public CE getPatientStudyEligibilityStatus() { 468 CE retVal = this.getTypedField(10, 0); 469 return retVal; 470 } 471 472 /** 473 * Returns 474 * CSR-10: "Patient Study Eligibility Status" - creates it if necessary 475 */ 476 public CE getCsr10_PatientStudyEligibilityStatus() { 477 CE retVal = this.getTypedField(10, 0); 478 return retVal; 479 } 480 481 482 /** 483 * Returns all repetitions of Study Randomization Date/time (CSR-11). 484 */ 485 public TS[] getStudyRandomizationDateTime() { 486 TS[] retVal = this.getTypedField(11, new TS[0]); 487 return retVal; 488 } 489 490 491 /** 492 * Returns all repetitions of Study Randomization Date/time (CSR-11). 493 */ 494 public TS[] getCsr11_StudyRandomizationDateTime() { 495 TS[] retVal = this.getTypedField(11, new TS[0]); 496 return retVal; 497 } 498 499 500 /** 501 * Returns a count of the current number of repetitions of Study Randomization Date/time (CSR-11). 502 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 503 * it will return zero. 504 */ 505 public int getStudyRandomizationDateTimeReps() { 506 return this.getReps(11); 507 } 508 509 510 /** 511 * Returns a specific repetition of 512 * CSR-11: "Study Randomization Date/time" - creates it if necessary 513 * 514 * @param rep The repetition index (0-indexed) 515 */ 516 public TS getStudyRandomizationDateTime(int rep) { 517 TS retVal = this.getTypedField(11, rep); 518 return retVal; 519 } 520 521 /** 522 * Returns a specific repetition of 523 * CSR-11: "Study Randomization Date/time" - creates it if necessary 524 * 525 * @param rep The repetition index (0-indexed) 526 */ 527 public TS getCsr11_StudyRandomizationDateTime(int rep) { 528 TS retVal = this.getTypedField(11, rep); 529 return retVal; 530 } 531 532 /** 533 * Returns a count of the current number of repetitions of Study Randomization Date/time (CSR-11). 534 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 535 * it will return zero. 536 */ 537 public int getCsr11_StudyRandomizationDateTimeReps() { 538 return this.getReps(11); 539 } 540 541 542 /** 543 * Inserts a repetition of 544 * CSR-11: "Study Randomization Date/time" at a specific index 545 * 546 * @param rep The repetition index (0-indexed) 547 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 548 */ 549 public TS insertStudyRandomizationDateTime(int rep) throws HL7Exception { 550 return (TS) super.insertRepetition(11, rep); 551 } 552 553 554 /** 555 * Inserts a repetition of 556 * CSR-11: "Study Randomization Date/time" at a specific index 557 * 558 * @param rep The repetition index (0-indexed) 559 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 560 */ 561 public TS insertCsr11_StudyRandomizationDateTime(int rep) throws HL7Exception { 562 return (TS) super.insertRepetition(11, rep); 563 } 564 565 566 /** 567 * Removes a repetition of 568 * CSR-11: "Study Randomization Date/time" at a specific index 569 * 570 * @param rep The repetition index (0-indexed) 571 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 572 */ 573 public TS removeStudyRandomizationDateTime(int rep) throws HL7Exception { 574 return (TS) super.removeRepetition(11, rep); 575 } 576 577 578 /** 579 * Removes a repetition of 580 * CSR-11: "Study Randomization Date/time" at a specific index 581 * 582 * @param rep The repetition index (0-indexed) 583 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 584 */ 585 public TS removeCsr11_StudyRandomizationDateTime(int rep) throws HL7Exception { 586 return (TS) super.removeRepetition(11, rep); 587 } 588 589 590 591 /** 592 * Returns all repetitions of Randomized Study Arm (CSR-12). 593 */ 594 public CE[] getRandomizedStudyArm() { 595 CE[] retVal = this.getTypedField(12, new CE[0]); 596 return retVal; 597 } 598 599 600 /** 601 * Returns all repetitions of Randomized Study Arm (CSR-12). 602 */ 603 public CE[] getCsr12_RandomizedStudyArm() { 604 CE[] retVal = this.getTypedField(12, new CE[0]); 605 return retVal; 606 } 607 608 609 /** 610 * Returns a count of the current number of repetitions of Randomized Study Arm (CSR-12). 611 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 612 * it will return zero. 613 */ 614 public int getRandomizedStudyArmReps() { 615 return this.getReps(12); 616 } 617 618 619 /** 620 * Returns a specific repetition of 621 * CSR-12: "Randomized Study Arm" - creates it if necessary 622 * 623 * @param rep The repetition index (0-indexed) 624 */ 625 public CE getRandomizedStudyArm(int rep) { 626 CE retVal = this.getTypedField(12, rep); 627 return retVal; 628 } 629 630 /** 631 * Returns a specific repetition of 632 * CSR-12: "Randomized Study Arm" - creates it if necessary 633 * 634 * @param rep The repetition index (0-indexed) 635 */ 636 public CE getCsr12_RandomizedStudyArm(int rep) { 637 CE retVal = this.getTypedField(12, rep); 638 return retVal; 639 } 640 641 /** 642 * Returns a count of the current number of repetitions of Randomized Study Arm (CSR-12). 643 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 644 * it will return zero. 645 */ 646 public int getCsr12_RandomizedStudyArmReps() { 647 return this.getReps(12); 648 } 649 650 651 /** 652 * Inserts a repetition of 653 * CSR-12: "Randomized Study Arm" at a specific index 654 * 655 * @param rep The repetition index (0-indexed) 656 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 657 */ 658 public CE insertRandomizedStudyArm(int rep) throws HL7Exception { 659 return (CE) super.insertRepetition(12, rep); 660 } 661 662 663 /** 664 * Inserts a repetition of 665 * CSR-12: "Randomized Study Arm" at a specific index 666 * 667 * @param rep The repetition index (0-indexed) 668 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 669 */ 670 public CE insertCsr12_RandomizedStudyArm(int rep) throws HL7Exception { 671 return (CE) super.insertRepetition(12, rep); 672 } 673 674 675 /** 676 * Removes a repetition of 677 * CSR-12: "Randomized Study Arm" at a specific index 678 * 679 * @param rep The repetition index (0-indexed) 680 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 681 */ 682 public CE removeRandomizedStudyArm(int rep) throws HL7Exception { 683 return (CE) super.removeRepetition(12, rep); 684 } 685 686 687 /** 688 * Removes a repetition of 689 * CSR-12: "Randomized Study Arm" at a specific index 690 * 691 * @param rep The repetition index (0-indexed) 692 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 693 */ 694 public CE removeCsr12_RandomizedStudyArm(int rep) throws HL7Exception { 695 return (CE) super.removeRepetition(12, rep); 696 } 697 698 699 700 /** 701 * Returns all repetitions of Stratum for Study Randomization (CSR-13). 702 */ 703 public CE[] getStratumForStudyRandomization() { 704 CE[] retVal = this.getTypedField(13, new CE[0]); 705 return retVal; 706 } 707 708 709 /** 710 * Returns all repetitions of Stratum for Study Randomization (CSR-13). 711 */ 712 public CE[] getCsr13_StratumForStudyRandomization() { 713 CE[] retVal = this.getTypedField(13, new CE[0]); 714 return retVal; 715 } 716 717 718 /** 719 * Returns a count of the current number of repetitions of Stratum for Study Randomization (CSR-13). 720 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 721 * it will return zero. 722 */ 723 public int getStratumForStudyRandomizationReps() { 724 return this.getReps(13); 725 } 726 727 728 /** 729 * Returns a specific repetition of 730 * CSR-13: "Stratum for Study Randomization" - creates it if necessary 731 * 732 * @param rep The repetition index (0-indexed) 733 */ 734 public CE getStratumForStudyRandomization(int rep) { 735 CE retVal = this.getTypedField(13, rep); 736 return retVal; 737 } 738 739 /** 740 * Returns a specific repetition of 741 * CSR-13: "Stratum for Study Randomization" - creates it if necessary 742 * 743 * @param rep The repetition index (0-indexed) 744 */ 745 public CE getCsr13_StratumForStudyRandomization(int rep) { 746 CE retVal = this.getTypedField(13, rep); 747 return retVal; 748 } 749 750 /** 751 * Returns a count of the current number of repetitions of Stratum for Study Randomization (CSR-13). 752 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 753 * it will return zero. 754 */ 755 public int getCsr13_StratumForStudyRandomizationReps() { 756 return this.getReps(13); 757 } 758 759 760 /** 761 * Inserts a repetition of 762 * CSR-13: "Stratum for Study Randomization" at a specific index 763 * 764 * @param rep The repetition index (0-indexed) 765 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 766 */ 767 public CE insertStratumForStudyRandomization(int rep) throws HL7Exception { 768 return (CE) super.insertRepetition(13, rep); 769 } 770 771 772 /** 773 * Inserts a repetition of 774 * CSR-13: "Stratum for Study Randomization" at a specific index 775 * 776 * @param rep The repetition index (0-indexed) 777 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 778 */ 779 public CE insertCsr13_StratumForStudyRandomization(int rep) throws HL7Exception { 780 return (CE) super.insertRepetition(13, rep); 781 } 782 783 784 /** 785 * Removes a repetition of 786 * CSR-13: "Stratum for Study Randomization" at a specific index 787 * 788 * @param rep The repetition index (0-indexed) 789 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 790 */ 791 public CE removeStratumForStudyRandomization(int rep) throws HL7Exception { 792 return (CE) super.removeRepetition(13, rep); 793 } 794 795 796 /** 797 * Removes a repetition of 798 * CSR-13: "Stratum for Study Randomization" at a specific index 799 * 800 * @param rep The repetition index (0-indexed) 801 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 802 */ 803 public CE removeCsr13_StratumForStudyRandomization(int rep) throws HL7Exception { 804 return (CE) super.removeRepetition(13, rep); 805 } 806 807 808 809 810 /** 811 * Returns 812 * CSR-14: "Patient Evaluability Status" - creates it if necessary 813 */ 814 public CE getPatientEvaluabilityStatus() { 815 CE retVal = this.getTypedField(14, 0); 816 return retVal; 817 } 818 819 /** 820 * Returns 821 * CSR-14: "Patient Evaluability Status" - creates it if necessary 822 */ 823 public CE getCsr14_PatientEvaluabilityStatus() { 824 CE retVal = this.getTypedField(14, 0); 825 return retVal; 826 } 827 828 829 830 /** 831 * Returns 832 * CSR-15: "Date/time Ended Study" - creates it if necessary 833 */ 834 public TS getDateTimeEndedStudy() { 835 TS retVal = this.getTypedField(15, 0); 836 return retVal; 837 } 838 839 /** 840 * Returns 841 * CSR-15: "Date/time Ended Study" - creates it if necessary 842 */ 843 public TS getCsr15_DateTimeEndedStudy() { 844 TS retVal = this.getTypedField(15, 0); 845 return retVal; 846 } 847 848 849 850 /** 851 * Returns 852 * CSR-16: "Reason Ended Study" - creates it if necessary 853 */ 854 public CE getReasonEndedStudy() { 855 CE retVal = this.getTypedField(16, 0); 856 return retVal; 857 } 858 859 /** 860 * Returns 861 * CSR-16: "Reason Ended Study" - creates it if necessary 862 */ 863 public CE getCsr16_ReasonEndedStudy() { 864 CE retVal = this.getTypedField(16, 0); 865 return retVal; 866 } 867 868 869 870 871 872 /** {@inheritDoc} */ 873 protected Type createNewTypeWithoutReflection(int field) { 874 switch (field) { 875 case 0: return new EI(getMessage()); 876 case 1: return new EI(getMessage()); 877 case 2: return new CE(getMessage()); 878 case 3: return new CX(getMessage()); 879 case 4: return new CX(getMessage()); 880 case 5: return new TS(getMessage()); 881 case 6: return new XCN(getMessage()); 882 case 7: return new XCN(getMessage()); 883 case 8: return new TS(getMessage()); 884 case 9: return new CE(getMessage()); 885 case 10: return new TS(getMessage()); 886 case 11: return new CE(getMessage()); 887 case 12: return new CE(getMessage()); 888 case 13: return new CE(getMessage()); 889 case 14: return new TS(getMessage()); 890 case 15: return new CE(getMessage()); 891 default: return null; 892 } 893 } 894 895 896} 897