Class XPN

All Implemented Interfaces:
Composite, Type, Visitable, Serializable

public class XPN extends AbstractComposite

Represents an HL7 XPN (extended person name) data type. This type consists of the following components:

  • family name (FN)
  • given name (ST)
  • second and further given names or initials thereof (ST)
  • suffix (e.g., JR or III) (ST)
  • prefix (e.g., DR) (ST)
  • degree (e.g., MD) (IS)
  • name type code (ID)
  • Name Representation code (ID)
  • name context (CE)
  • name validity range (DR)
  • name assembly order (ID)
See Also:
  • Constructor Details

    • XPN

      public XPN(Message message)
      Creates a new XPN type
  • Method Details

    • getComponents

      public Type[] getComponents()
      Returns an array containing the data elements.
    • getComponent

      public Type getComponent(int number) throws DataTypeException
      Returns an individual data component.
      Parameters:
      number - The component number (0-indexed)
      Throws:
      DataTypeException - if the given element number is out of range.
    • getFamilyName

      public FN getFamilyName()
      Returns family name (component 1). This is a convenience method that saves you from casting and handling an exception.
    • getXpn1_FamilyName

      Returns family name (component 1). This is a convenience method that saves you from casting and handling an exception.
    • getGivenName

      public ST getGivenName()
      Returns given name (component 2). This is a convenience method that saves you from casting and handling an exception.
    • getXpn2_GivenName

      Returns given name (component 2). This is a convenience method that saves you from casting and handling an exception.
    • getSecondAndFurtherGivenNamesOrInitialsThereof

      Returns second and further given names or initials thereof (component 3). This is a convenience method that saves you from casting and handling an exception.
    • getXpn3_SecondAndFurtherGivenNamesOrInitialsThereof

      Returns second and further given names or initials thereof (component 3). This is a convenience method that saves you from casting and handling an exception.
    • getSuffixEgJRorIII

      Returns suffix (e.g., JR or III) (component 4). This is a convenience method that saves you from casting and handling an exception.
    • getXpn4_SuffixEgJRorIII

      Returns suffix (e.g., JR or III) (component 4). This is a convenience method that saves you from casting and handling an exception.
    • getPrefixEgDR

      public ST getPrefixEgDR()
      Returns prefix (e.g., DR) (component 5). This is a convenience method that saves you from casting and handling an exception.
    • getXpn5_PrefixEgDR

      Returns prefix (e.g., DR) (component 5). This is a convenience method that saves you from casting and handling an exception.
    • getDegreeEgMD

      public IS getDegreeEgMD()
      Returns degree (e.g., MD) (component 6). This is a convenience method that saves you from casting and handling an exception.
    • getXpn6_DegreeEgMD

      Returns degree (e.g., MD) (component 6). This is a convenience method that saves you from casting and handling an exception.
    • getNameTypeCode

      public ID getNameTypeCode()
      Returns name type code (component 7). This is a convenience method that saves you from casting and handling an exception.
    • getXpn7_NameTypeCode

      Returns name type code (component 7). This is a convenience method that saves you from casting and handling an exception.
    • getNameRepresentationCode

      Returns Name Representation code (component 8). This is a convenience method that saves you from casting and handling an exception.
    • getXpn8_NameRepresentationCode

      Returns Name Representation code (component 8). This is a convenience method that saves you from casting and handling an exception.
    • getNameContext

      public CE getNameContext()
      Returns name context (component 9). This is a convenience method that saves you from casting and handling an exception.
    • getXpn9_NameContext

      Returns name context (component 9). This is a convenience method that saves you from casting and handling an exception.
    • getNameValidityRange

      Returns name validity range (component 10). This is a convenience method that saves you from casting and handling an exception.
    • getXpn10_NameValidityRange

      Returns name validity range (component 10). This is a convenience method that saves you from casting and handling an exception.
    • getNameAssemblyOrder

      Returns name assembly order (component 11). This is a convenience method that saves you from casting and handling an exception.
    • getXpn11_NameAssemblyOrder

      Returns name assembly order (component 11). This is a convenience method that saves you from casting and handling an exception.