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.v26.segment; 035 036// import ca.uhn.hl7v2.model.v26.group.*; 037import ca.uhn.hl7v2.model.v26.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 PRC message segment (Pricing). 049 * This segment has the following fields:</p> 050 * <ul> 051 * <li>PRC-1: Primary Key Value-PRC (CWE) <b> </b> 052 * <li>PRC-2: Facility ID-PRC (CWE) <b>optional repeating</b> 053 * <li>PRC-3: Department (CWE) <b>optional repeating</b> 054 * <li>PRC-4: Valid Patient Classes (IS) <b>optional repeating</b> 055 * <li>PRC-5: Price (CP) <b>optional repeating</b> 056 * <li>PRC-6: Formula (ST) <b>optional repeating</b> 057 * <li>PRC-7: Minimum Quantity (NM) <b>optional </b> 058 * <li>PRC-8: Maximum Quantity (NM) <b>optional </b> 059 * <li>PRC-9: Minimum Price (MO) <b>optional </b> 060 * <li>PRC-10: Maximum Price (MO) <b>optional </b> 061 * <li>PRC-11: Effective Start Date (DTM) <b>optional </b> 062 * <li>PRC-12: Effective End Date (DTM) <b>optional </b> 063 * <li>PRC-13: Price Override Flag (IS) <b>optional </b> 064 * <li>PRC-14: Billing Category (CWE) <b>optional repeating</b> 065 * <li>PRC-15: Chargeable Flag (ID) <b>optional </b> 066 * <li>PRC-16: Active/Inactive Flag (ID) <b>optional </b> 067 * <li>PRC-17: Cost (MO) <b>optional </b> 068 * <li>PRC-18: Charge on Indicator (IS) <b>optional </b> 069 * </ul> 070 */ 071@SuppressWarnings("unused") 072public class PRC extends AbstractSegment { 073 074 /** 075 * Creates a new PRC segment 076 */ 077 public PRC(Group parent, ModelClassFactory factory) { 078 super(parent, factory); 079 init(factory); 080 } 081 082 private void init(ModelClassFactory factory) { 083 try { 084 this.add(CWE.class, true, 1, 250, new Object[]{ getMessage() }, "Primary Key Value-PRC"); 085 this.add(CWE.class, false, 0, 250, new Object[]{ getMessage() }, "Facility ID-PRC"); 086 this.add(CWE.class, false, 0, 250, new Object[]{ getMessage() }, "Department"); 087 this.add(IS.class, false, 0, 1, new Object[]{ getMessage(), new Integer(4) }, "Valid Patient Classes"); 088 this.add(CP.class, false, 0, 12, new Object[]{ getMessage() }, "Price"); 089 this.add(ST.class, false, 0, 200, new Object[]{ getMessage() }, "Formula"); 090 this.add(NM.class, false, 1, 4, new Object[]{ getMessage() }, "Minimum Quantity"); 091 this.add(NM.class, false, 1, 4, new Object[]{ getMessage() }, "Maximum Quantity"); 092 this.add(MO.class, false, 1, 12, new Object[]{ getMessage() }, "Minimum Price"); 093 this.add(MO.class, false, 1, 12, new Object[]{ getMessage() }, "Maximum Price"); 094 this.add(DTM.class, false, 1, 24, new Object[]{ getMessage() }, "Effective Start Date"); 095 this.add(DTM.class, false, 1, 24, new Object[]{ getMessage() }, "Effective End Date"); 096 this.add(IS.class, false, 1, 1, new Object[]{ getMessage(), new Integer(268) }, "Price Override Flag"); 097 this.add(CWE.class, false, 0, 250, new Object[]{ getMessage() }, "Billing Category"); 098 this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(136) }, "Chargeable Flag"); 099 this.add(ID.class, false, 1, 1, new Object[]{ getMessage(), new Integer(183) }, "Active/Inactive Flag"); 100 this.add(MO.class, false, 1, 12, new Object[]{ getMessage() }, "Cost"); 101 this.add(IS.class, false, 1, 1, new Object[]{ getMessage(), new Integer(269) }, "Charge on Indicator"); 102 } catch(HL7Exception e) { 103 log.error("Unexpected error creating PRC - this is probably a bug in the source code generator.", e); 104 } 105 } 106 107 108 109 /** 110 * Returns 111 * PRC-1: "Primary Key Value-PRC" - creates it if necessary 112 */ 113 public CWE getPrimaryKeyValuePRC() { 114 CWE retVal = this.getTypedField(1, 0); 115 return retVal; 116 } 117 118 /** 119 * Returns 120 * PRC-1: "Primary Key Value-PRC" - creates it if necessary 121 */ 122 public CWE getPrc1_PrimaryKeyValuePRC() { 123 CWE retVal = this.getTypedField(1, 0); 124 return retVal; 125 } 126 127 128 /** 129 * Returns all repetitions of Facility ID-PRC (PRC-2). 130 */ 131 public CWE[] getFacilityIDPRC() { 132 CWE[] retVal = this.getTypedField(2, new CWE[0]); 133 return retVal; 134 } 135 136 137 /** 138 * Returns all repetitions of Facility ID-PRC (PRC-2). 139 */ 140 public CWE[] getPrc2_FacilityIDPRC() { 141 CWE[] retVal = this.getTypedField(2, new CWE[0]); 142 return retVal; 143 } 144 145 146 /** 147 * Returns a count of the current number of repetitions of Facility ID-PRC (PRC-2). 148 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 149 * it will return zero. 150 */ 151 public int getFacilityIDPRCReps() { 152 return this.getReps(2); 153 } 154 155 156 /** 157 * Returns a specific repetition of 158 * PRC-2: "Facility ID-PRC" - creates it if necessary 159 * 160 * @param rep The repetition index (0-indexed) 161 */ 162 public CWE getFacilityIDPRC(int rep) { 163 CWE retVal = this.getTypedField(2, rep); 164 return retVal; 165 } 166 167 /** 168 * Returns a specific repetition of 169 * PRC-2: "Facility ID-PRC" - creates it if necessary 170 * 171 * @param rep The repetition index (0-indexed) 172 */ 173 public CWE getPrc2_FacilityIDPRC(int rep) { 174 CWE retVal = this.getTypedField(2, rep); 175 return retVal; 176 } 177 178 /** 179 * Returns a count of the current number of repetitions of Facility ID-PRC (PRC-2). 180 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 181 * it will return zero. 182 */ 183 public int getPrc2_FacilityIDPRCReps() { 184 return this.getReps(2); 185 } 186 187 188 /** 189 * Inserts a repetition of 190 * PRC-2: "Facility ID-PRC" at a specific index 191 * 192 * @param rep The repetition index (0-indexed) 193 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 194 */ 195 public CWE insertFacilityIDPRC(int rep) throws HL7Exception { 196 return (CWE) super.insertRepetition(2, rep); 197 } 198 199 200 /** 201 * Inserts a repetition of 202 * PRC-2: "Facility ID-PRC" at a specific index 203 * 204 * @param rep The repetition index (0-indexed) 205 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 206 */ 207 public CWE insertPrc2_FacilityIDPRC(int rep) throws HL7Exception { 208 return (CWE) super.insertRepetition(2, rep); 209 } 210 211 212 /** 213 * Removes a repetition of 214 * PRC-2: "Facility ID-PRC" at a specific index 215 * 216 * @param rep The repetition index (0-indexed) 217 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 218 */ 219 public CWE removeFacilityIDPRC(int rep) throws HL7Exception { 220 return (CWE) super.removeRepetition(2, rep); 221 } 222 223 224 /** 225 * Removes a repetition of 226 * PRC-2: "Facility ID-PRC" at a specific index 227 * 228 * @param rep The repetition index (0-indexed) 229 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 230 */ 231 public CWE removePrc2_FacilityIDPRC(int rep) throws HL7Exception { 232 return (CWE) super.removeRepetition(2, rep); 233 } 234 235 236 237 /** 238 * Returns all repetitions of Department (PRC-3). 239 */ 240 public CWE[] getDepartment() { 241 CWE[] retVal = this.getTypedField(3, new CWE[0]); 242 return retVal; 243 } 244 245 246 /** 247 * Returns all repetitions of Department (PRC-3). 248 */ 249 public CWE[] getPrc3_Department() { 250 CWE[] retVal = this.getTypedField(3, new CWE[0]); 251 return retVal; 252 } 253 254 255 /** 256 * Returns a count of the current number of repetitions of Department (PRC-3). 257 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 258 * it will return zero. 259 */ 260 public int getDepartmentReps() { 261 return this.getReps(3); 262 } 263 264 265 /** 266 * Returns a specific repetition of 267 * PRC-3: "Department" - creates it if necessary 268 * 269 * @param rep The repetition index (0-indexed) 270 */ 271 public CWE getDepartment(int rep) { 272 CWE retVal = this.getTypedField(3, rep); 273 return retVal; 274 } 275 276 /** 277 * Returns a specific repetition of 278 * PRC-3: "Department" - creates it if necessary 279 * 280 * @param rep The repetition index (0-indexed) 281 */ 282 public CWE getPrc3_Department(int rep) { 283 CWE retVal = this.getTypedField(3, rep); 284 return retVal; 285 } 286 287 /** 288 * Returns a count of the current number of repetitions of Department (PRC-3). 289 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 290 * it will return zero. 291 */ 292 public int getPrc3_DepartmentReps() { 293 return this.getReps(3); 294 } 295 296 297 /** 298 * Inserts a repetition of 299 * PRC-3: "Department" at a specific index 300 * 301 * @param rep The repetition index (0-indexed) 302 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 303 */ 304 public CWE insertDepartment(int rep) throws HL7Exception { 305 return (CWE) super.insertRepetition(3, rep); 306 } 307 308 309 /** 310 * Inserts a repetition of 311 * PRC-3: "Department" at a specific index 312 * 313 * @param rep The repetition index (0-indexed) 314 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 315 */ 316 public CWE insertPrc3_Department(int rep) throws HL7Exception { 317 return (CWE) super.insertRepetition(3, rep); 318 } 319 320 321 /** 322 * Removes a repetition of 323 * PRC-3: "Department" at a specific index 324 * 325 * @param rep The repetition index (0-indexed) 326 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 327 */ 328 public CWE removeDepartment(int rep) throws HL7Exception { 329 return (CWE) super.removeRepetition(3, rep); 330 } 331 332 333 /** 334 * Removes a repetition of 335 * PRC-3: "Department" at a specific index 336 * 337 * @param rep The repetition index (0-indexed) 338 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 339 */ 340 public CWE removePrc3_Department(int rep) throws HL7Exception { 341 return (CWE) super.removeRepetition(3, rep); 342 } 343 344 345 346 /** 347 * Returns all repetitions of Valid Patient Classes (PRC-4). 348 */ 349 public IS[] getValidPatientClasses() { 350 IS[] retVal = this.getTypedField(4, new IS[0]); 351 return retVal; 352 } 353 354 355 /** 356 * Returns all repetitions of Valid Patient Classes (PRC-4). 357 */ 358 public IS[] getPrc4_ValidPatientClasses() { 359 IS[] retVal = this.getTypedField(4, new IS[0]); 360 return retVal; 361 } 362 363 364 /** 365 * Returns a count of the current number of repetitions of Valid Patient Classes (PRC-4). 366 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 367 * it will return zero. 368 */ 369 public int getValidPatientClassesReps() { 370 return this.getReps(4); 371 } 372 373 374 /** 375 * Returns a specific repetition of 376 * PRC-4: "Valid Patient Classes" - creates it if necessary 377 * 378 * @param rep The repetition index (0-indexed) 379 */ 380 public IS getValidPatientClasses(int rep) { 381 IS retVal = this.getTypedField(4, rep); 382 return retVal; 383 } 384 385 /** 386 * Returns a specific repetition of 387 * PRC-4: "Valid Patient Classes" - creates it if necessary 388 * 389 * @param rep The repetition index (0-indexed) 390 */ 391 public IS getPrc4_ValidPatientClasses(int rep) { 392 IS retVal = this.getTypedField(4, rep); 393 return retVal; 394 } 395 396 /** 397 * Returns a count of the current number of repetitions of Valid Patient Classes (PRC-4). 398 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 399 * it will return zero. 400 */ 401 public int getPrc4_ValidPatientClassesReps() { 402 return this.getReps(4); 403 } 404 405 406 /** 407 * Inserts a repetition of 408 * PRC-4: "Valid Patient Classes" at a specific index 409 * 410 * @param rep The repetition index (0-indexed) 411 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 412 */ 413 public IS insertValidPatientClasses(int rep) throws HL7Exception { 414 return (IS) super.insertRepetition(4, rep); 415 } 416 417 418 /** 419 * Inserts a repetition of 420 * PRC-4: "Valid Patient Classes" at a specific index 421 * 422 * @param rep The repetition index (0-indexed) 423 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 424 */ 425 public IS insertPrc4_ValidPatientClasses(int rep) throws HL7Exception { 426 return (IS) super.insertRepetition(4, rep); 427 } 428 429 430 /** 431 * Removes a repetition of 432 * PRC-4: "Valid Patient Classes" at a specific index 433 * 434 * @param rep The repetition index (0-indexed) 435 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 436 */ 437 public IS removeValidPatientClasses(int rep) throws HL7Exception { 438 return (IS) super.removeRepetition(4, rep); 439 } 440 441 442 /** 443 * Removes a repetition of 444 * PRC-4: "Valid Patient Classes" at a specific index 445 * 446 * @param rep The repetition index (0-indexed) 447 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 448 */ 449 public IS removePrc4_ValidPatientClasses(int rep) throws HL7Exception { 450 return (IS) super.removeRepetition(4, rep); 451 } 452 453 454 455 /** 456 * Returns all repetitions of Price (PRC-5). 457 */ 458 public CP[] getPrice() { 459 CP[] retVal = this.getTypedField(5, new CP[0]); 460 return retVal; 461 } 462 463 464 /** 465 * Returns all repetitions of Price (PRC-5). 466 */ 467 public CP[] getPrc5_Price() { 468 CP[] retVal = this.getTypedField(5, new CP[0]); 469 return retVal; 470 } 471 472 473 /** 474 * Returns a count of the current number of repetitions of Price (PRC-5). 475 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 476 * it will return zero. 477 */ 478 public int getPriceReps() { 479 return this.getReps(5); 480 } 481 482 483 /** 484 * Returns a specific repetition of 485 * PRC-5: "Price" - creates it if necessary 486 * 487 * @param rep The repetition index (0-indexed) 488 */ 489 public CP getPrice(int rep) { 490 CP retVal = this.getTypedField(5, rep); 491 return retVal; 492 } 493 494 /** 495 * Returns a specific repetition of 496 * PRC-5: "Price" - creates it if necessary 497 * 498 * @param rep The repetition index (0-indexed) 499 */ 500 public CP getPrc5_Price(int rep) { 501 CP retVal = this.getTypedField(5, rep); 502 return retVal; 503 } 504 505 /** 506 * Returns a count of the current number of repetitions of Price (PRC-5). 507 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 508 * it will return zero. 509 */ 510 public int getPrc5_PriceReps() { 511 return this.getReps(5); 512 } 513 514 515 /** 516 * Inserts a repetition of 517 * PRC-5: "Price" at a specific index 518 * 519 * @param rep The repetition index (0-indexed) 520 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 521 */ 522 public CP insertPrice(int rep) throws HL7Exception { 523 return (CP) super.insertRepetition(5, rep); 524 } 525 526 527 /** 528 * Inserts a repetition of 529 * PRC-5: "Price" at a specific index 530 * 531 * @param rep The repetition index (0-indexed) 532 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 533 */ 534 public CP insertPrc5_Price(int rep) throws HL7Exception { 535 return (CP) super.insertRepetition(5, rep); 536 } 537 538 539 /** 540 * Removes a repetition of 541 * PRC-5: "Price" at a specific index 542 * 543 * @param rep The repetition index (0-indexed) 544 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 545 */ 546 public CP removePrice(int rep) throws HL7Exception { 547 return (CP) super.removeRepetition(5, rep); 548 } 549 550 551 /** 552 * Removes a repetition of 553 * PRC-5: "Price" at a specific index 554 * 555 * @param rep The repetition index (0-indexed) 556 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 557 */ 558 public CP removePrc5_Price(int rep) throws HL7Exception { 559 return (CP) super.removeRepetition(5, rep); 560 } 561 562 563 564 /** 565 * Returns all repetitions of Formula (PRC-6). 566 */ 567 public ST[] getFormula() { 568 ST[] retVal = this.getTypedField(6, new ST[0]); 569 return retVal; 570 } 571 572 573 /** 574 * Returns all repetitions of Formula (PRC-6). 575 */ 576 public ST[] getPrc6_Formula() { 577 ST[] retVal = this.getTypedField(6, new ST[0]); 578 return retVal; 579 } 580 581 582 /** 583 * Returns a count of the current number of repetitions of Formula (PRC-6). 584 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 585 * it will return zero. 586 */ 587 public int getFormulaReps() { 588 return this.getReps(6); 589 } 590 591 592 /** 593 * Returns a specific repetition of 594 * PRC-6: "Formula" - creates it if necessary 595 * 596 * @param rep The repetition index (0-indexed) 597 */ 598 public ST getFormula(int rep) { 599 ST retVal = this.getTypedField(6, rep); 600 return retVal; 601 } 602 603 /** 604 * Returns a specific repetition of 605 * PRC-6: "Formula" - creates it if necessary 606 * 607 * @param rep The repetition index (0-indexed) 608 */ 609 public ST getPrc6_Formula(int rep) { 610 ST retVal = this.getTypedField(6, rep); 611 return retVal; 612 } 613 614 /** 615 * Returns a count of the current number of repetitions of Formula (PRC-6). 616 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 617 * it will return zero. 618 */ 619 public int getPrc6_FormulaReps() { 620 return this.getReps(6); 621 } 622 623 624 /** 625 * Inserts a repetition of 626 * PRC-6: "Formula" at a specific index 627 * 628 * @param rep The repetition index (0-indexed) 629 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 630 */ 631 public ST insertFormula(int rep) throws HL7Exception { 632 return (ST) super.insertRepetition(6, rep); 633 } 634 635 636 /** 637 * Inserts a repetition of 638 * PRC-6: "Formula" at a specific index 639 * 640 * @param rep The repetition index (0-indexed) 641 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 642 */ 643 public ST insertPrc6_Formula(int rep) throws HL7Exception { 644 return (ST) super.insertRepetition(6, rep); 645 } 646 647 648 /** 649 * Removes a repetition of 650 * PRC-6: "Formula" at a specific index 651 * 652 * @param rep The repetition index (0-indexed) 653 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 654 */ 655 public ST removeFormula(int rep) throws HL7Exception { 656 return (ST) super.removeRepetition(6, rep); 657 } 658 659 660 /** 661 * Removes a repetition of 662 * PRC-6: "Formula" at a specific index 663 * 664 * @param rep The repetition index (0-indexed) 665 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 666 */ 667 public ST removePrc6_Formula(int rep) throws HL7Exception { 668 return (ST) super.removeRepetition(6, rep); 669 } 670 671 672 673 674 /** 675 * Returns 676 * PRC-7: "Minimum Quantity" - creates it if necessary 677 */ 678 public NM getMinimumQuantity() { 679 NM retVal = this.getTypedField(7, 0); 680 return retVal; 681 } 682 683 /** 684 * Returns 685 * PRC-7: "Minimum Quantity" - creates it if necessary 686 */ 687 public NM getPrc7_MinimumQuantity() { 688 NM retVal = this.getTypedField(7, 0); 689 return retVal; 690 } 691 692 693 694 /** 695 * Returns 696 * PRC-8: "Maximum Quantity" - creates it if necessary 697 */ 698 public NM getMaximumQuantity() { 699 NM retVal = this.getTypedField(8, 0); 700 return retVal; 701 } 702 703 /** 704 * Returns 705 * PRC-8: "Maximum Quantity" - creates it if necessary 706 */ 707 public NM getPrc8_MaximumQuantity() { 708 NM retVal = this.getTypedField(8, 0); 709 return retVal; 710 } 711 712 713 714 /** 715 * Returns 716 * PRC-9: "Minimum Price" - creates it if necessary 717 */ 718 public MO getMinimumPrice() { 719 MO retVal = this.getTypedField(9, 0); 720 return retVal; 721 } 722 723 /** 724 * Returns 725 * PRC-9: "Minimum Price" - creates it if necessary 726 */ 727 public MO getPrc9_MinimumPrice() { 728 MO retVal = this.getTypedField(9, 0); 729 return retVal; 730 } 731 732 733 734 /** 735 * Returns 736 * PRC-10: "Maximum Price" - creates it if necessary 737 */ 738 public MO getMaximumPrice() { 739 MO retVal = this.getTypedField(10, 0); 740 return retVal; 741 } 742 743 /** 744 * Returns 745 * PRC-10: "Maximum Price" - creates it if necessary 746 */ 747 public MO getPrc10_MaximumPrice() { 748 MO retVal = this.getTypedField(10, 0); 749 return retVal; 750 } 751 752 753 754 /** 755 * Returns 756 * PRC-11: "Effective Start Date" - creates it if necessary 757 */ 758 public DTM getEffectiveStartDate() { 759 DTM retVal = this.getTypedField(11, 0); 760 return retVal; 761 } 762 763 /** 764 * Returns 765 * PRC-11: "Effective Start Date" - creates it if necessary 766 */ 767 public DTM getPrc11_EffectiveStartDate() { 768 DTM retVal = this.getTypedField(11, 0); 769 return retVal; 770 } 771 772 773 774 /** 775 * Returns 776 * PRC-12: "Effective End Date" - creates it if necessary 777 */ 778 public DTM getEffectiveEndDate() { 779 DTM retVal = this.getTypedField(12, 0); 780 return retVal; 781 } 782 783 /** 784 * Returns 785 * PRC-12: "Effective End Date" - creates it if necessary 786 */ 787 public DTM getPrc12_EffectiveEndDate() { 788 DTM retVal = this.getTypedField(12, 0); 789 return retVal; 790 } 791 792 793 794 /** 795 * Returns 796 * PRC-13: "Price Override Flag" - creates it if necessary 797 */ 798 public IS getPriceOverrideFlag() { 799 IS retVal = this.getTypedField(13, 0); 800 return retVal; 801 } 802 803 /** 804 * Returns 805 * PRC-13: "Price Override Flag" - creates it if necessary 806 */ 807 public IS getPrc13_PriceOverrideFlag() { 808 IS retVal = this.getTypedField(13, 0); 809 return retVal; 810 } 811 812 813 /** 814 * Returns all repetitions of Billing Category (PRC-14). 815 */ 816 public CWE[] getBillingCategory() { 817 CWE[] retVal = this.getTypedField(14, new CWE[0]); 818 return retVal; 819 } 820 821 822 /** 823 * Returns all repetitions of Billing Category (PRC-14). 824 */ 825 public CWE[] getPrc14_BillingCategory() { 826 CWE[] retVal = this.getTypedField(14, new CWE[0]); 827 return retVal; 828 } 829 830 831 /** 832 * Returns a count of the current number of repetitions of Billing Category (PRC-14). 833 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 834 * it will return zero. 835 */ 836 public int getBillingCategoryReps() { 837 return this.getReps(14); 838 } 839 840 841 /** 842 * Returns a specific repetition of 843 * PRC-14: "Billing Category" - creates it if necessary 844 * 845 * @param rep The repetition index (0-indexed) 846 */ 847 public CWE getBillingCategory(int rep) { 848 CWE retVal = this.getTypedField(14, rep); 849 return retVal; 850 } 851 852 /** 853 * Returns a specific repetition of 854 * PRC-14: "Billing Category" - creates it if necessary 855 * 856 * @param rep The repetition index (0-indexed) 857 */ 858 public CWE getPrc14_BillingCategory(int rep) { 859 CWE retVal = this.getTypedField(14, rep); 860 return retVal; 861 } 862 863 /** 864 * Returns a count of the current number of repetitions of Billing Category (PRC-14). 865 * This method does not create a repetition, so if no repetitions have currently been defined or accessed, 866 * it will return zero. 867 */ 868 public int getPrc14_BillingCategoryReps() { 869 return this.getReps(14); 870 } 871 872 873 /** 874 * Inserts a repetition of 875 * PRC-14: "Billing Category" at a specific index 876 * 877 * @param rep The repetition index (0-indexed) 878 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 879 */ 880 public CWE insertBillingCategory(int rep) throws HL7Exception { 881 return (CWE) super.insertRepetition(14, rep); 882 } 883 884 885 /** 886 * Inserts a repetition of 887 * PRC-14: "Billing Category" at a specific index 888 * 889 * @param rep The repetition index (0-indexed) 890 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 891 */ 892 public CWE insertPrc14_BillingCategory(int rep) throws HL7Exception { 893 return (CWE) super.insertRepetition(14, rep); 894 } 895 896 897 /** 898 * Removes a repetition of 899 * PRC-14: "Billing Category" at a specific index 900 * 901 * @param rep The repetition index (0-indexed) 902 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 903 */ 904 public CWE removeBillingCategory(int rep) throws HL7Exception { 905 return (CWE) super.removeRepetition(14, rep); 906 } 907 908 909 /** 910 * Removes a repetition of 911 * PRC-14: "Billing Category" at a specific index 912 * 913 * @param rep The repetition index (0-indexed) 914 * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) 915 */ 916 public CWE removePrc14_BillingCategory(int rep) throws HL7Exception { 917 return (CWE) super.removeRepetition(14, rep); 918 } 919 920 921 922 923 /** 924 * Returns 925 * PRC-15: "Chargeable Flag" - creates it if necessary 926 */ 927 public ID getChargeableFlag() { 928 ID retVal = this.getTypedField(15, 0); 929 return retVal; 930 } 931 932 /** 933 * Returns 934 * PRC-15: "Chargeable Flag" - creates it if necessary 935 */ 936 public ID getPrc15_ChargeableFlag() { 937 ID retVal = this.getTypedField(15, 0); 938 return retVal; 939 } 940 941 942 943 /** 944 * Returns 945 * PRC-16: "Active/Inactive Flag" - creates it if necessary 946 */ 947 public ID getActiveInactiveFlag() { 948 ID retVal = this.getTypedField(16, 0); 949 return retVal; 950 } 951 952 /** 953 * Returns 954 * PRC-16: "Active/Inactive Flag" - creates it if necessary 955 */ 956 public ID getPrc16_ActiveInactiveFlag() { 957 ID retVal = this.getTypedField(16, 0); 958 return retVal; 959 } 960 961 962 963 /** 964 * Returns 965 * PRC-17: "Cost" - creates it if necessary 966 */ 967 public MO getCost() { 968 MO retVal = this.getTypedField(17, 0); 969 return retVal; 970 } 971 972 /** 973 * Returns 974 * PRC-17: "Cost" - creates it if necessary 975 */ 976 public MO getPrc17_Cost() { 977 MO retVal = this.getTypedField(17, 0); 978 return retVal; 979 } 980 981 982 983 /** 984 * Returns 985 * PRC-18: "Charge on Indicator" - creates it if necessary 986 */ 987 public IS getChargeOnIndicator() { 988 IS retVal = this.getTypedField(18, 0); 989 return retVal; 990 } 991 992 /** 993 * Returns 994 * PRC-18: "Charge on Indicator" - creates it if necessary 995 */ 996 public IS getPrc18_ChargeOnIndicator() { 997 IS retVal = this.getTypedField(18, 0); 998 return retVal; 999 } 1000 1001 1002 1003 1004 1005 /** {@inheritDoc} */ 1006 protected Type createNewTypeWithoutReflection(int field) { 1007 switch (field) { 1008 case 0: return new CWE(getMessage()); 1009 case 1: return new CWE(getMessage()); 1010 case 2: return new CWE(getMessage()); 1011 case 3: return new IS(getMessage(), new Integer( 4 )); 1012 case 4: return new CP(getMessage()); 1013 case 5: return new ST(getMessage()); 1014 case 6: return new NM(getMessage()); 1015 case 7: return new NM(getMessage()); 1016 case 8: return new MO(getMessage()); 1017 case 9: return new MO(getMessage()); 1018 case 10: return new DTM(getMessage()); 1019 case 11: return new DTM(getMessage()); 1020 case 12: return new IS(getMessage(), new Integer( 268 )); 1021 case 13: return new CWE(getMessage()); 1022 case 14: return new ID(getMessage(), new Integer( 136 )); 1023 case 15: return new ID(getMessage(), new Integer( 183 )); 1024 case 16: return new MO(getMessage()); 1025 case 17: return new IS(getMessage(), new Integer( 269 )); 1026 default: return null; 1027 } 1028 } 1029 1030 1031} 1032