Class VXR_V03

All Implemented Interfaces:
Group, Message, Structure, Visitable, Serializable

public class VXR_V03 extends AbstractMessage

Represents a VXR_V03 message structure (see chapter ?). This structure contains the following elements:

  • 1: MSH (Message header segment)
  • 2: MSA (Message acknowledgement segment)
  • 3: QRD (Query definition segment)
  • 4: QRF (Query filter segment) optional
  • 5: PID (Patient Identification)
  • 6: PD1 (Patient Demographic) optional
  • 7: NK1 (Next of kin) optional repeating
  • 8: VXR_V03_PATIENT_VISIT (a Group object) optional
  • 9: VXR_V03_INSURANCE (a Group object) optional repeating
  • 10: VXR_V03_ORDER (a Group object) optional repeating
See Also:
  • Constructor Details

    • VXR_V03

      public VXR_V03()
      Creates a new VXR_V03 message with DefaultModelClassFactory.
    • VXR_V03

      public VXR_V03(ModelClassFactory factory)
      Creates a new VXR_V03 message with custom ModelClassFactory.
  • Method Details

    • getVersion

      public String getVersion()
      Returns "2.3"
      Specified by:
      getVersion in interface Message
      Overrides:
      getVersion in class AbstractMessage
    • getMSH

      public MSH getMSH()

      Returns MSH (Message header segment) - creates it if necessary

    • getMSA

      public MSA getMSA()

      Returns MSA (Message acknowledgement segment) - creates it if necessary

    • getQRD

      public QRD getQRD()

      Returns QRD (Query definition segment) - creates it if necessary

    • getQRF

      public QRF getQRF()

      Returns QRF (Query filter segment) - creates it if necessary

    • getPID

      public PID getPID()

      Returns PID (Patient Identification) - creates it if necessary

    • getPD1

      public PD1 getPD1()

      Returns PD1 (Patient Demographic) - creates it if necessary

    • getNK1

      public NK1 getNK1()

      Returns the first repetition of NK1 (Next of kin) - creates it if necessary

    • getNK1

      public NK1 getNK1(int rep)

      Returns a specific repetition of NK1 (Next of kin) - creates it if necessary

      Parameters:
      rep - The repetition index (0-indexed, i.e. the first repetition is at index 0)
      Throws:
      HL7Exception - if the repetition requested is more than one greater than the number of existing repetitions.
    • getNK1Reps

      public int getNK1Reps()

      Returns the number of existing repetitions of NK1

    • getNK1All

      public List<NK1> getNK1All() throws HL7Exception

      Returns a non-modifiable List containing all current existing repetitions of NK1.

      Note that unlike getNK1(), this method will not create any reps if none are already present, so an empty list may be returned.

      Throws:
      HL7Exception
    • insertNK1

      public void insertNK1(NK1 structure, int rep) throws HL7Exception

      Inserts a specific repetition of NK1 (Next of kin)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • insertNK1

      public NK1 insertNK1(int rep) throws HL7Exception

      Inserts a specific repetition of NK1 (Next of kin)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • removeNK1

      public NK1 removeNK1(int rep) throws HL7Exception

      Removes a specific repetition of NK1 (Next of kin)

      Throws:
      HL7Exception
      See Also:
    • getPATIENT_VISIT

      Returns PATIENT_VISIT (a Group object) - creates it if necessary

    • getINSURANCE

      Returns the first repetition of INSURANCE (a Group object) - creates it if necessary

    • getINSURANCE

      public VXR_V03_INSURANCE getINSURANCE(int rep)

      Returns a specific repetition of INSURANCE (a Group object) - creates it if necessary

      Parameters:
      rep - The repetition index (0-indexed, i.e. the first repetition is at index 0)
      Throws:
      HL7Exception - if the repetition requested is more than one greater than the number of existing repetitions.
    • getINSURANCEReps

      public int getINSURANCEReps()

      Returns the number of existing repetitions of INSURANCE

    • getINSURANCEAll

      Returns a non-modifiable List containing all current existing repetitions of INSURANCE.

      Note that unlike getINSURANCE(), this method will not create any reps if none are already present, so an empty list may be returned.

      Throws:
      HL7Exception
    • insertINSURANCE

      public void insertINSURANCE(VXR_V03_INSURANCE structure, int rep) throws HL7Exception

      Inserts a specific repetition of INSURANCE (a Group object)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • insertINSURANCE

      Inserts a specific repetition of INSURANCE (a Group object)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • removeINSURANCE

      Removes a specific repetition of INSURANCE (a Group object)

      Throws:
      HL7Exception
      See Also:
    • getORDER

      Returns the first repetition of ORDER (a Group object) - creates it if necessary

    • getORDER

      public VXR_V03_ORDER getORDER(int rep)

      Returns a specific repetition of ORDER (a Group object) - creates it if necessary

      Parameters:
      rep - The repetition index (0-indexed, i.e. the first repetition is at index 0)
      Throws:
      HL7Exception - if the repetition requested is more than one greater than the number of existing repetitions.
    • getORDERReps

      public int getORDERReps()

      Returns the number of existing repetitions of ORDER

    • getORDERAll

      Returns a non-modifiable List containing all current existing repetitions of ORDER.

      Note that unlike getORDER(), this method will not create any reps if none are already present, so an empty list may be returned.

      Throws:
      HL7Exception
    • insertORDER

      public void insertORDER(VXR_V03_ORDER structure, int rep) throws HL7Exception

      Inserts a specific repetition of ORDER (a Group object)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • insertORDER

      public VXR_V03_ORDER insertORDER(int rep) throws HL7Exception

      Inserts a specific repetition of ORDER (a Group object)

      Throws:
      HL7Exception
      See Also:
      • AbstractGroup#insertRepetition(Structure, int)
    • removeORDER

      public VXR_V03_ORDER removeORDER(int rep) throws HL7Exception

      Removes a specific repetition of ORDER (a Group object)

      Throws:
      HL7Exception
      See Also: