All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ca.uhn.hl7v2.model.v24.segment.ORC Maven / Gradle / Ivy

There is a newer version: 2.3
Show newest version
/*
 * This class is an auto-generated source file for a HAPI
 * HL7 v2.x standard structure class.
 *
 * For more information, visit: http://hl7api.sourceforge.net/
 */

package ca.uhn.hl7v2.model.v24.segment;

// import ca.uhn.hl7v2.model.v24.group.*;
import ca.uhn.hl7v2.model.v24.datatype.*;
import ca.uhn.log.HapiLogFactory;
import ca.uhn.hl7v2.HL7Exception;
import ca.uhn.hl7v2.parser.ModelClassFactory;
import ca.uhn.hl7v2.parser.DefaultModelClassFactory;
import ca.uhn.hl7v2.model.AbstractMessage;
import ca.uhn.hl7v2.model.Group;
import ca.uhn.hl7v2.model.Type;
import ca.uhn.hl7v2.model.AbstractSegment;
import ca.uhn.hl7v2.model.Varies;

/**
 *

Represents an HL7 ORC message segment (Common Order). * This segment has the following fields:

*
    *
  • ORC-1: Order Control (ID) *
  • ORC-2: Placer Order Number (EI) optional *
  • ORC-3: Filler Order Number (EI) optional *
  • ORC-4: Placer Group Number (EI) optional *
  • ORC-5: Order Status (ID) optional *
  • ORC-6: Response Flag (ID) optional *
  • ORC-7: Quantity/Timing (TQ) optional repeating *
  • ORC-8: Parent Order (EIP) optional *
  • ORC-9: Date/Time of Transaction (TS) optional *
  • ORC-10: Entered By (XCN) optional repeating *
  • ORC-11: Verified By (XCN) optional repeating *
  • ORC-12: Ordering Provider (XCN) optional repeating *
  • ORC-13: Enterer's Location (PL) optional *
  • ORC-14: Call Back Phone Number (XTN) optional repeating *
  • ORC-15: Order Effective Date/Time (TS) optional *
  • ORC-16: Order Control Code Reason (CE) optional *
  • ORC-17: Entering Organization (CE) optional *
  • ORC-18: Entering Device (CE) optional *
  • ORC-19: Action By (XCN) optional repeating *
  • ORC-20: Advanced Beneficiary Notice Code (CE) optional *
  • ORC-21: Ordering Facility Name (XON) optional repeating *
  • ORC-22: Ordering Facility Address (XAD) optional repeating *
  • ORC-23: Ordering Facility Phone Number (XTN) optional repeating *
  • ORC-24: Ordering Provider Address (XAD) optional repeating *
  • ORC-25: Order Status Modifier (CWE) optional *
*/ public class ORC extends AbstractSegment { /** * Creates a new ORC segment */ public ORC(Group parent, ModelClassFactory factory) { super(parent, factory); init(factory); } private void init(ModelClassFactory factory) { try { this.add(ID.class, true, 1, 2, new Object[]{ getMessage() }, "Order Control"); this.add(EI.class, false, 1, 22, new Object[]{ getMessage(), new Integer(0) }, "Placer Order Number"); this.add(EI.class, false, 1, 22, new Object[]{ getMessage(), new Integer(0) }, "Filler Order Number"); this.add(EI.class, false, 1, 22, new Object[]{ getMessage(), new Integer(0) }, "Placer Group Number"); this.add(ID.class, false, 1, 2, new Object[]{ getMessage() }, "Order Status"); this.add(ID.class, false, 1, 1, new Object[]{ getMessage() }, "Response Flag"); this.add(TQ.class, false, 0, 200, new Object[]{ getMessage(), new Integer(0) }, "Quantity/Timing"); this.add(EIP.class, false, 1, 200, new Object[]{ getMessage(), new Integer(0) }, "Parent Order"); this.add(TS.class, false, 1, 26, new Object[]{ getMessage(), new Integer(0) }, "Date/Time of Transaction"); this.add(XCN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Entered By"); this.add(XCN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Verified By"); this.add(XCN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Ordering Provider"); this.add(PL.class, false, 1, 80, new Object[]{ getMessage(), new Integer(0) }, "Enterer's Location"); this.add(XTN.class, false, 2, 250, new Object[]{ getMessage(), new Integer(0) }, "Call Back Phone Number"); this.add(TS.class, false, 1, 26, new Object[]{ getMessage(), new Integer(0) }, "Order Effective Date/Time"); this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(0) }, "Order Control Code Reason"); this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(0) }, "Entering Organization"); this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(0) }, "Entering Device"); this.add(XCN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Action By"); this.add(CE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(339) }, "Advanced Beneficiary Notice Code"); this.add(XON.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Ordering Facility Name"); this.add(XAD.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Ordering Facility Address"); this.add(XTN.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Ordering Facility Phone Number"); this.add(XAD.class, false, 0, 250, new Object[]{ getMessage(), new Integer(0) }, "Ordering Provider Address"); this.add(CWE.class, false, 1, 250, new Object[]{ getMessage(), new Integer(0) }, "Order Status Modifier"); } catch(HL7Exception e) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected error creating ORC - this is probably a bug in the source code generator.", e); } } /** * Returns * ORC-1: "Order Control" - creates it if necessary */ public ID getOrderControl() { ID ret = null; try { Type t = this.getField(1, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-1: "Order Control" - creates it if necessary */ public ID getOrc1_OrderControl() { ID ret = null; try { Type t = this.getField(1, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-2: "Placer Order Number" - creates it if necessary */ public EI getPlacerOrderNumber() { EI ret = null; try { Type t = this.getField(2, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-2: "Placer Order Number" - creates it if necessary */ public EI getOrc2_PlacerOrderNumber() { EI ret = null; try { Type t = this.getField(2, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-3: "Filler Order Number" - creates it if necessary */ public EI getFillerOrderNumber() { EI ret = null; try { Type t = this.getField(3, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-3: "Filler Order Number" - creates it if necessary */ public EI getOrc3_FillerOrderNumber() { EI ret = null; try { Type t = this.getField(3, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-4: "Placer Group Number" - creates it if necessary */ public EI getPlacerGroupNumber() { EI ret = null; try { Type t = this.getField(4, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-4: "Placer Group Number" - creates it if necessary */ public EI getOrc4_PlacerGroupNumber() { EI ret = null; try { Type t = this.getField(4, 0); ret = (EI)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-5: "Order Status" - creates it if necessary */ public ID getOrderStatus() { ID ret = null; try { Type t = this.getField(5, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-5: "Order Status" - creates it if necessary */ public ID getOrc5_OrderStatus() { ID ret = null; try { Type t = this.getField(5, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-6: "Response Flag" - creates it if necessary */ public ID getResponseFlag() { ID ret = null; try { Type t = this.getField(6, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-6: "Response Flag" - creates it if necessary */ public ID getOrc6_ResponseFlag() { ID ret = null; try { Type t = this.getField(6, 0); ret = (ID)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns all repetitions of Quantity/Timing (ORC-7). */ public TQ[] getQuantityTiming() { TQ[] ret = null; try { Type[] t = this.getField(7); ret = new TQ[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (TQ)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Quantity/Timing (ORC-7). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getQuantityTimingReps() { TQ[] ret = null; try { Type[] t = this.getField(7); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-7: "Quantity/Timing" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public TQ getQuantityTiming(int rep) { TQ ret = null; try { Type t = this.getField(7, rep); ret = (TQ)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-7: "Quantity/Timing" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public TQ getOrc7_QuantityTiming(int rep) { TQ ret = null; try { Type t = this.getField(7, rep); ret = (TQ)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Quantity/Timing (ORC-7). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc7_QuantityTimingReps() { TQ[] ret = null; try { Type[] t = this.getField(7); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-7: "Quantity/Timing" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public TQ insertQuantityTiming(int rep) throws HL7Exception { return (TQ) super.insertRepetition(7, rep); } /** * Inserts a repetition of * ORC-7: "Quantity/Timing" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public TQ insertOrc7_QuantityTiming(int rep) throws HL7Exception { return (TQ) super.insertRepetition(7, rep); } /** * Removes a repetition of * ORC-7: "Quantity/Timing" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public TQ removeQuantityTiming(int rep) throws HL7Exception { return (TQ) super.removeRepetition(7, rep); } /** * Removes a repetition of * ORC-7: "Quantity/Timing" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public TQ removeOrc7_QuantityTiming(int rep) throws HL7Exception { return (TQ) super.removeRepetition(7, rep); } /** * Returns * ORC-8: "Parent Order" - creates it if necessary */ public EIP getParentOrder() { EIP ret = null; try { Type t = this.getField(8, 0); ret = (EIP)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-8: "Parent Order" - creates it if necessary */ public EIP getOrc8_ParentOrder() { EIP ret = null; try { Type t = this.getField(8, 0); ret = (EIP)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-9: "Date/Time of Transaction" - creates it if necessary */ public TS getDateTimeOfTransaction() { TS ret = null; try { Type t = this.getField(9, 0); ret = (TS)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-9: "Date/Time of Transaction" - creates it if necessary */ public TS getOrc9_DateTimeOfTransaction() { TS ret = null; try { Type t = this.getField(9, 0); ret = (TS)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns all repetitions of Entered By (ORC-10). */ public XCN[] getEnteredBy() { XCN[] ret = null; try { Type[] t = this.getField(10); ret = new XCN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XCN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Entered By (ORC-10). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getEnteredByReps() { XCN[] ret = null; try { Type[] t = this.getField(10); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-10: "Entered By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getEnteredBy(int rep) { XCN ret = null; try { Type t = this.getField(10, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-10: "Entered By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getOrc10_EnteredBy(int rep) { XCN ret = null; try { Type t = this.getField(10, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Entered By (ORC-10). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc10_EnteredByReps() { XCN[] ret = null; try { Type[] t = this.getField(10); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-10: "Entered By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertEnteredBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(10, rep); } /** * Inserts a repetition of * ORC-10: "Entered By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertOrc10_EnteredBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(10, rep); } /** * Removes a repetition of * ORC-10: "Entered By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeEnteredBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(10, rep); } /** * Removes a repetition of * ORC-10: "Entered By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeOrc10_EnteredBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(10, rep); } /** * Returns all repetitions of Verified By (ORC-11). */ public XCN[] getVerifiedBy() { XCN[] ret = null; try { Type[] t = this.getField(11); ret = new XCN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XCN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Verified By (ORC-11). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getVerifiedByReps() { XCN[] ret = null; try { Type[] t = this.getField(11); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-11: "Verified By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getVerifiedBy(int rep) { XCN ret = null; try { Type t = this.getField(11, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-11: "Verified By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getOrc11_VerifiedBy(int rep) { XCN ret = null; try { Type t = this.getField(11, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Verified By (ORC-11). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc11_VerifiedByReps() { XCN[] ret = null; try { Type[] t = this.getField(11); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-11: "Verified By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertVerifiedBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(11, rep); } /** * Inserts a repetition of * ORC-11: "Verified By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertOrc11_VerifiedBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(11, rep); } /** * Removes a repetition of * ORC-11: "Verified By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeVerifiedBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(11, rep); } /** * Removes a repetition of * ORC-11: "Verified By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeOrc11_VerifiedBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(11, rep); } /** * Returns all repetitions of Ordering Provider (ORC-12). */ public XCN[] getOrderingProvider() { XCN[] ret = null; try { Type[] t = this.getField(12); ret = new XCN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XCN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Provider (ORC-12). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrderingProviderReps() { XCN[] ret = null; try { Type[] t = this.getField(12); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-12: "Ordering Provider" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getOrderingProvider(int rep) { XCN ret = null; try { Type t = this.getField(12, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-12: "Ordering Provider" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getOrc12_OrderingProvider(int rep) { XCN ret = null; try { Type t = this.getField(12, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Provider (ORC-12). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc12_OrderingProviderReps() { XCN[] ret = null; try { Type[] t = this.getField(12); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-12: "Ordering Provider" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertOrderingProvider(int rep) throws HL7Exception { return (XCN) super.insertRepetition(12, rep); } /** * Inserts a repetition of * ORC-12: "Ordering Provider" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertOrc12_OrderingProvider(int rep) throws HL7Exception { return (XCN) super.insertRepetition(12, rep); } /** * Removes a repetition of * ORC-12: "Ordering Provider" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeOrderingProvider(int rep) throws HL7Exception { return (XCN) super.removeRepetition(12, rep); } /** * Removes a repetition of * ORC-12: "Ordering Provider" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeOrc12_OrderingProvider(int rep) throws HL7Exception { return (XCN) super.removeRepetition(12, rep); } /** * Returns * ORC-13: "Enterer's Location" - creates it if necessary */ public PL getEntererSLocation() { PL ret = null; try { Type t = this.getField(13, 0); ret = (PL)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-13: "Enterer's Location" - creates it if necessary */ public PL getOrc13_EntererSLocation() { PL ret = null; try { Type t = this.getField(13, 0); ret = (PL)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns all repetitions of Call Back Phone Number (ORC-14). */ public XTN[] getCallBackPhoneNumber() { XTN[] ret = null; try { Type[] t = this.getField(14); ret = new XTN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XTN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Call Back Phone Number (ORC-14). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getCallBackPhoneNumberReps() { XTN[] ret = null; try { Type[] t = this.getField(14); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-14: "Call Back Phone Number" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XTN getCallBackPhoneNumber(int rep) { XTN ret = null; try { Type t = this.getField(14, rep); ret = (XTN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-14: "Call Back Phone Number" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XTN getOrc14_CallBackPhoneNumber(int rep) { XTN ret = null; try { Type t = this.getField(14, rep); ret = (XTN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Call Back Phone Number (ORC-14). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc14_CallBackPhoneNumberReps() { XTN[] ret = null; try { Type[] t = this.getField(14); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-14: "Call Back Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN insertCallBackPhoneNumber(int rep) throws HL7Exception { return (XTN) super.insertRepetition(14, rep); } /** * Inserts a repetition of * ORC-14: "Call Back Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN insertOrc14_CallBackPhoneNumber(int rep) throws HL7Exception { return (XTN) super.insertRepetition(14, rep); } /** * Removes a repetition of * ORC-14: "Call Back Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN removeCallBackPhoneNumber(int rep) throws HL7Exception { return (XTN) super.removeRepetition(14, rep); } /** * Removes a repetition of * ORC-14: "Call Back Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN removeOrc14_CallBackPhoneNumber(int rep) throws HL7Exception { return (XTN) super.removeRepetition(14, rep); } /** * Returns * ORC-15: "Order Effective Date/Time" - creates it if necessary */ public TS getOrderEffectiveDateTime() { TS ret = null; try { Type t = this.getField(15, 0); ret = (TS)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-15: "Order Effective Date/Time" - creates it if necessary */ public TS getOrc15_OrderEffectiveDateTime() { TS ret = null; try { Type t = this.getField(15, 0); ret = (TS)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-16: "Order Control Code Reason" - creates it if necessary */ public CE getOrderControlCodeReason() { CE ret = null; try { Type t = this.getField(16, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-16: "Order Control Code Reason" - creates it if necessary */ public CE getOrc16_OrderControlCodeReason() { CE ret = null; try { Type t = this.getField(16, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-17: "Entering Organization" - creates it if necessary */ public CE getEnteringOrganization() { CE ret = null; try { Type t = this.getField(17, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-17: "Entering Organization" - creates it if necessary */ public CE getOrc17_EnteringOrganization() { CE ret = null; try { Type t = this.getField(17, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-18: "Entering Device" - creates it if necessary */ public CE getEnteringDevice() { CE ret = null; try { Type t = this.getField(18, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-18: "Entering Device" - creates it if necessary */ public CE getOrc18_EnteringDevice() { CE ret = null; try { Type t = this.getField(18, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns all repetitions of Action By (ORC-19). */ public XCN[] getActionBy() { XCN[] ret = null; try { Type[] t = this.getField(19); ret = new XCN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XCN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Action By (ORC-19). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getActionByReps() { XCN[] ret = null; try { Type[] t = this.getField(19); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-19: "Action By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getActionBy(int rep) { XCN ret = null; try { Type t = this.getField(19, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-19: "Action By" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XCN getOrc19_ActionBy(int rep) { XCN ret = null; try { Type t = this.getField(19, rep); ret = (XCN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Action By (ORC-19). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc19_ActionByReps() { XCN[] ret = null; try { Type[] t = this.getField(19); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-19: "Action By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertActionBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(19, rep); } /** * Inserts a repetition of * ORC-19: "Action By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN insertOrc19_ActionBy(int rep) throws HL7Exception { return (XCN) super.insertRepetition(19, rep); } /** * Removes a repetition of * ORC-19: "Action By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeActionBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(19, rep); } /** * Removes a repetition of * ORC-19: "Action By" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XCN removeOrc19_ActionBy(int rep) throws HL7Exception { return (XCN) super.removeRepetition(19, rep); } /** * Returns * ORC-20: "Advanced Beneficiary Notice Code" - creates it if necessary */ public CE getAdvancedBeneficiaryNoticeCode() { CE ret = null; try { Type t = this.getField(20, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-20: "Advanced Beneficiary Notice Code" - creates it if necessary */ public CE getOrc20_AdvancedBeneficiaryNoticeCode() { CE ret = null; try { Type t = this.getField(20, 0); ret = (CE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns all repetitions of Ordering Facility Name (ORC-21). */ public XON[] getOrderingFacilityName() { XON[] ret = null; try { Type[] t = this.getField(21); ret = new XON[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XON)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Name (ORC-21). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrderingFacilityNameReps() { XON[] ret = null; try { Type[] t = this.getField(21); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-21: "Ordering Facility Name" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XON getOrderingFacilityName(int rep) { XON ret = null; try { Type t = this.getField(21, rep); ret = (XON)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-21: "Ordering Facility Name" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XON getOrc21_OrderingFacilityName(int rep) { XON ret = null; try { Type t = this.getField(21, rep); ret = (XON)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Name (ORC-21). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc21_OrderingFacilityNameReps() { XON[] ret = null; try { Type[] t = this.getField(21); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-21: "Ordering Facility Name" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XON insertOrderingFacilityName(int rep) throws HL7Exception { return (XON) super.insertRepetition(21, rep); } /** * Inserts a repetition of * ORC-21: "Ordering Facility Name" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XON insertOrc21_OrderingFacilityName(int rep) throws HL7Exception { return (XON) super.insertRepetition(21, rep); } /** * Removes a repetition of * ORC-21: "Ordering Facility Name" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XON removeOrderingFacilityName(int rep) throws HL7Exception { return (XON) super.removeRepetition(21, rep); } /** * Removes a repetition of * ORC-21: "Ordering Facility Name" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XON removeOrc21_OrderingFacilityName(int rep) throws HL7Exception { return (XON) super.removeRepetition(21, rep); } /** * Returns all repetitions of Ordering Facility Address (ORC-22). */ public XAD[] getOrderingFacilityAddress() { XAD[] ret = null; try { Type[] t = this.getField(22); ret = new XAD[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XAD)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Address (ORC-22). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrderingFacilityAddressReps() { XAD[] ret = null; try { Type[] t = this.getField(22); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-22: "Ordering Facility Address" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XAD getOrderingFacilityAddress(int rep) { XAD ret = null; try { Type t = this.getField(22, rep); ret = (XAD)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-22: "Ordering Facility Address" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XAD getOrc22_OrderingFacilityAddress(int rep) { XAD ret = null; try { Type t = this.getField(22, rep); ret = (XAD)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Address (ORC-22). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc22_OrderingFacilityAddressReps() { XAD[] ret = null; try { Type[] t = this.getField(22); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-22: "Ordering Facility Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD insertOrderingFacilityAddress(int rep) throws HL7Exception { return (XAD) super.insertRepetition(22, rep); } /** * Inserts a repetition of * ORC-22: "Ordering Facility Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD insertOrc22_OrderingFacilityAddress(int rep) throws HL7Exception { return (XAD) super.insertRepetition(22, rep); } /** * Removes a repetition of * ORC-22: "Ordering Facility Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD removeOrderingFacilityAddress(int rep) throws HL7Exception { return (XAD) super.removeRepetition(22, rep); } /** * Removes a repetition of * ORC-22: "Ordering Facility Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD removeOrc22_OrderingFacilityAddress(int rep) throws HL7Exception { return (XAD) super.removeRepetition(22, rep); } /** * Returns all repetitions of Ordering Facility Phone Number (ORC-23). */ public XTN[] getOrderingFacilityPhoneNumber() { XTN[] ret = null; try { Type[] t = this.getField(23); ret = new XTN[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XTN)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Phone Number (ORC-23). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrderingFacilityPhoneNumberReps() { XTN[] ret = null; try { Type[] t = this.getField(23); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-23: "Ordering Facility Phone Number" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XTN getOrderingFacilityPhoneNumber(int rep) { XTN ret = null; try { Type t = this.getField(23, rep); ret = (XTN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-23: "Ordering Facility Phone Number" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XTN getOrc23_OrderingFacilityPhoneNumber(int rep) { XTN ret = null; try { Type t = this.getField(23, rep); ret = (XTN)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Facility Phone Number (ORC-23). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc23_OrderingFacilityPhoneNumberReps() { XTN[] ret = null; try { Type[] t = this.getField(23); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-23: "Ordering Facility Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN insertOrderingFacilityPhoneNumber(int rep) throws HL7Exception { return (XTN) super.insertRepetition(23, rep); } /** * Inserts a repetition of * ORC-23: "Ordering Facility Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN insertOrc23_OrderingFacilityPhoneNumber(int rep) throws HL7Exception { return (XTN) super.insertRepetition(23, rep); } /** * Removes a repetition of * ORC-23: "Ordering Facility Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN removeOrderingFacilityPhoneNumber(int rep) throws HL7Exception { return (XTN) super.removeRepetition(23, rep); } /** * Removes a repetition of * ORC-23: "Ordering Facility Phone Number" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XTN removeOrc23_OrderingFacilityPhoneNumber(int rep) throws HL7Exception { return (XTN) super.removeRepetition(23, rep); } /** * Returns all repetitions of Ordering Provider Address (ORC-24). */ public XAD[] getOrderingProviderAddress() { XAD[] ret = null; try { Type[] t = this.getField(24); ret = new XAD[t.length]; for (int i = 0; i < ret.length; i++) { ret[i] = (XAD)t[i]; } } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Provider Address (ORC-24). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrderingProviderAddressReps() { XAD[] ret = null; try { Type[] t = this.getField(24); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Returns a specific repetition of * ORC-24: "Ordering Provider Address" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XAD getOrderingProviderAddress(int rep) { XAD ret = null; try { Type t = this.getField(24, rep); ret = (XAD)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a specific repetition of * ORC-24: "Ordering Provider Address" - creates it if necessary * * @param rep The repetition index (0-indexed) */ public XAD getOrc24_OrderingProviderAddress(int rep) { XAD ret = null; try { Type t = this.getField(24, rep); ret = (XAD)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns a count of the current number of repetitions of Ordering Provider Address (ORC-24). * This method does not create a repetition, so if no repetitions have currently been defined or accessed, * it will return zero. */ public int getOrc24_OrderingProviderAddressReps() { XAD[] ret = null; try { Type[] t = this.getField(24); return t.length; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } } /** * Inserts a repetition of * ORC-24: "Ordering Provider Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD insertOrderingProviderAddress(int rep) throws HL7Exception { return (XAD) super.insertRepetition(24, rep); } /** * Inserts a repetition of * ORC-24: "Ordering Provider Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD insertOrc24_OrderingProviderAddress(int rep) throws HL7Exception { return (XAD) super.insertRepetition(24, rep); } /** * Removes a repetition of * ORC-24: "Ordering Provider Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD removeOrderingProviderAddress(int rep) throws HL7Exception { return (XAD) super.removeRepetition(24, rep); } /** * Removes a repetition of * ORC-24: "Ordering Provider Address" at a specific index * * @param rep The repetition index (0-indexed) * @throws HL7Exception If the rep is invalid (below 0, or too high for the allowable repetitions) */ public XAD removeOrc24_OrderingProviderAddress(int rep) throws HL7Exception { return (XAD) super.removeRepetition(24, rep); } /** * Returns * ORC-25: "Order Status Modifier" - creates it if necessary */ public CWE getOrderStatusModifier() { CWE ret = null; try { Type t = this.getField(25, 0); ret = (CWE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** * Returns * ORC-25: "Order Status Modifier" - creates it if necessary */ public CWE getOrc25_OrderStatusModifier() { CWE ret = null; try { Type t = this.getField(25, 0); ret = (CWE)t; } catch (ClassCastException cce) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", cce); throw new RuntimeException(cce); } catch (HL7Exception he) { HapiLogFactory.getHapiLog(this.getClass()).error("Unexpected problem obtaining field value. This is a bug.", he); throw new RuntimeException(he); } return ret; } /** {@inheritDoc} */ protected Type createNewTypeWithoutReflection(int field) { switch (field) { case 0: return new ID(getMessage(), new Integer( 119 )); case 1: return new EI(getMessage()); case 2: return new EI(getMessage()); case 3: return new EI(getMessage()); case 4: return new ID(getMessage(), new Integer( 38 )); case 5: return new ID(getMessage(), new Integer( 121 )); case 6: return new TQ(getMessage()); case 7: return new EIP(getMessage()); case 8: return new TS(getMessage()); case 9: return new XCN(getMessage()); case 10: return new XCN(getMessage()); case 11: return new XCN(getMessage()); case 12: return new PL(getMessage()); case 13: return new XTN(getMessage()); case 14: return new TS(getMessage()); case 15: return new CE(getMessage()); case 16: return new CE(getMessage()); case 17: return new CE(getMessage()); case 18: return new XCN(getMessage()); case 19: return new CE(getMessage()); case 20: return new XON(getMessage()); case 21: return new XAD(getMessage()); case 22: return new XTN(getMessage()); case 23: return new XAD(getMessage()); case 24: return new CWE(getMessage()); default: return null; } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy