cdac.medinfo.sdk.hl7282.baselibs

## Class PLN

- java.lang.Object
- - cdac.medinfo.sdk.hl7282.baselibs.CompositeDataType
  - - cdac.medinfo.sdk.hl7282.baselibs.PLN

- All Implemented Interfaces:
    IDataType

      public class PLN
      extends CompositeDataType

  PLN - Practitioner license or other Id number

  This data type specifies a practitioner's license number, or other ID number such as UPIN, Medicare and Medicaid number, and associated detail.

  Represents an HL7 PLN data type. This data type has the following attributes:

  1. ID Number (ST)Required
  2. Type of ID Number (CWE)Required
  3. State/other Qualifying Information (ST)Optional
  4. Expiration Date (DT)Optional

  This class provides accessors & mutators for the elements mentioned above. This class override the equal method, to check whether some other object is "equal to" this one.

  User can also create Data Type through `DataElementFactory`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `PLN()` Default Constructor for PLN
    `PLN(int iComponentType, IDataTypeMap objIDataTypeMap)` Constructor for PLN class which takes two arguments and sets the value in the respective member variable.
    `PLN(int iComponentType, int iMinLength, int iMaxLength, java.lang.String strCLength, IDataTypeMap objIDataTypeMap)` Constructor for PLN class which takes five arguments and sets the value in the respective member variable.
    `PLN(int iComponentType, int iMinLength, int iMaxLength, java.lang.String strCLength, int ITableNo, IDataTypeMap objIDataTypeMap)` Constructor for PLN class which takes six arguments and sets the value in the respective member variable.
    `PLN(int iMinLength, int iMaxLength, java.lang.String strCLength, int iComponentType)` Constructor for CQ class which takes four arguments and sets the value in the respective member variable.
    `PLN(int iMinLength, int iMaxLength, java.lang.String strCLength, int iTableNo, int iComponentType)` Constructor for PLN class which takes five arguments and sets the value in the respective member variable.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `equals(java.lang.Object objObject)` This method checks the equality of Object.
    `DT` | `getExpirationDate()` Returns Expiration Date
    `ST` | `getIDNumber()` Returns ID Number
    `ST` | `getStateOtherQualifyingInformation()` Returns State/other Qualifying Information
    `CWE` | `getTypeOfIDNumber()` Returns Type of ID Number
    `void` | `setExpirationDate(DT objDT)` Sets the ExpirationDate.
    `void` | `setExpirationDate(java.lang.String strExpirationDate)` Sets the ExpirationDate.
    `void` | `setIdNumber(ST objST)` Sets the IdNumber.
    `void` | `setIdNumber(java.lang.String strIdNumber)` Sets the IdNumber.
    `void` | `setStateOtherQualifyingInformation(ST objST)` Sets the StateOtherQualifyingInformation.
    `void` | `setStateOtherQualifyingInformation(java.lang.String strStateOtherQualifyingInfo)` Sets the StateOtherQualifyingInformation.
    `void` | `setTypeOfIdNumber(CWE objCWE)` Sets the TypeOfIdNumber.
    `void` | `setTypeOfIdNumber(java.lang.String strTypeOfIdNumber)` Sets the TypeOfIdNumber.
    `boolean` | `validate()` The Method validates the Input value,and if validated properly then returns true.

    - ### Methods inherited from class cdac.medinfo.sdk.hl7282.baselibs.CompositeDataType

      `copy, dumpDataType, getAttributes, getDataTypeName, getLength, getValue, isPrimitive, read, setValue, write, writeToXML`

    - ### Methods inherited from class java.lang.Object

      `getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### PLN

          public PLN()

      Default Constructor for PLN

    - #### PLN

          public PLN(int iMinLength,
             int iMaxLength,
             java.lang.String strCLength,
             int iComponentType)
              throws InvalidComponentTypeException

      Constructor for CQ class which takes four arguments and sets the value in the respective member variable.
      Parameters:
        `iMinLength` - The Minimum length the DataType can have.
        `iMaxLength` - The Maximum length the DataType can have.
        `iCLength` - The Conformance length the DataType can have.
        `iComponentType` - The Type of the component i.e Component or a subcomponent.
      Throws:
        `InvalidComponentTypeException` - - if Component Type is not specified or valid.

    - #### PLN

          public PLN(int iMinLength,
             int iMaxLength,
             java.lang.String strCLength,
             int iTableNo,
             int iComponentType)
              throws InvalidComponentTypeException

      Constructor for PLN class which takes five arguments and sets the value in the respective member variable.
      Parameters:
        `iMinLength` - The Minimum length the DataType can have.
        `iMaxLength` - The Maximum length the DataType can have.
        `iCLength` - The Conformance length the DataType can have.
        `iTableNo` - The Table number to which the value for the component is specified.
        `iComponentType` - The Type of the component i.e Component or a subcomponent.
      Throws:
        `InvalidComponentTypeException` - - if Component Type is not specified or valid.

    - #### PLN

          public PLN(int iComponentType,
             IDataTypeMap objIDataTypeMap)

      Constructor for PLN class which takes two arguments and sets the value in the respective member variable.
      Parameters:
        `objIDataTypeMap` - object of Data Type Map.
        `iComponentType` - The Type of the component i.e Component or a subcomponent.
      Throws:
        `InvalidComponentTypeException` - - if Component Type is not specified or valid.

    - #### PLN

          public PLN(int iComponentType,
             int iMinLength,
             int iMaxLength,
             java.lang.String strCLength,
             IDataTypeMap objIDataTypeMap)

      Constructor for PLN class which takes five arguments and sets the value in the respective member variable.
      Parameters:
        `objIDataTypeMap` - object of Data Type Map.
        `iComponentType` - The Type of the component i.e Component or a subcomponent.
        `iMinLength` - The Minimum length the DataType can have.
        `iMaxLength` - The Maximum length the DataType can have.
        `iCLength` - The Conformance length the DataType can have.
      Throws:
        `InvalidComponentTypeException` - - if Component Type is not specified or valid.

    - #### PLN

          public PLN(int iComponentType,
             int iMinLength,
             int iMaxLength,
             java.lang.String strCLength,
             int ITableNo,
             IDataTypeMap objIDataTypeMap)

      Constructor for PLN class which takes six arguments and sets the value in the respective member variable.
      Parameters:
        `objIDataTypeMap` - object of Data Type Map.
        `iComponentType` - The Type of the component i.e Component or a subcomponent.
        `iMinLength` - The Minimum length the DataType can have.
        `iMaxLength` - The Maximum length the DataType can have.
        `iCLength` - The Conformance length the DataType can have.
        `iTableNo` - The Table number to which the value for the component is specified.
      Throws:
        `InvalidComponentTypeException` - - if Component Type is not specified or valid.

  - ### Method Detail

    - #### setIdNumber

          public void setIdNumber(java.lang.String strIdNumber)

      Sets the IdNumber.
      Parameters:
        `strIdNumber` - Specifies the license number or other ID number such as UPIN, Medicare and Medicaid number.

    - #### setIdNumber

          public void setIdNumber(ST objST)

      Sets the IdNumber.
      Parameters:
        `objST` - Specifies the license number or other ID number such as UPIN, Medicare and Medicaid number.

    - #### setTypeOfIdNumber

          public void setTypeOfIdNumber(java.lang.String strTypeOfIdNumber)

      Sets the TypeOfIdNumber.
      Parameters:
        `strTypeOfIdNumber` - Specifies the type of number.

    - #### setTypeOfIdNumber

          public void setTypeOfIdNumber(CWE objCWE)

      Sets the TypeOfIdNumber.
      Parameters:
        `objCWE` - Specifies the type of number.

    - #### setStateOtherQualifyingInformation

          public void setStateOtherQualifyingInformation(java.lang.String strStateOtherQualifyingInfo)

      Sets the StateOtherQualifyingInformation.
      Parameters:
        `strStateOtherQualifyingInfo` - Specifies the state or province in which the license or ID is valid

    - #### setStateOtherQualifyingInformation

          public void setStateOtherQualifyingInformation(ST objST)

      Sets the StateOtherQualifyingInformation.
      Parameters:
        `objST` - Specifies the state or province in which the license or ID is valid

    - #### setExpirationDate

          public void setExpirationDate(java.lang.String strExpirationDate)

      Sets the ExpirationDate.
      Parameters:
        `strExpirationDate` - Specifies the date when the license or ID is no longer valid.

    - #### setExpirationDate

          public void setExpirationDate(DT objDT)

      Sets the ExpirationDate.
      Parameters:
        `objDT` - Specifies the date when the license or ID is no longer valid.

    - #### getIDNumber

          public ST getIDNumber()

      Returns ID Number
      Returns:
        ST - data type.

    - #### getTypeOfIDNumber

          public CWE getTypeOfIDNumber()

      Returns Type of ID Number
      Returns:
        CWE - data type.

    - #### getStateOtherQualifyingInformation

          public ST getStateOtherQualifyingInformation()

      Returns State/other Qualifying Information
      Returns:
        ST - data type.

    - #### getExpirationDate

          public DT getExpirationDate()

      Returns Expiration Date
      Returns:
        DT - data type.

    - #### validate

          public boolean validate()
                           throws InvalidDataTypeException

      The Method validates the Input value,and if validated properly then returns true. Here the validetion is based on the compulsory fields for the Datatype.
      Specified by:
        `validate` in interface `IDataType`
      Overrides:
        `validate` in class `CompositeDataType`
      Returns:
        boolean - true or false.
      Throws:
        `InvalidDataTypeException` - - if Invalid values is entered or Mandatory field is missing.

    - #### equals

          public boolean equals(java.lang.Object objObject)

      This method checks the equality of Object.
      Overrides:
        `equals` in class `java.lang.Object`
      Parameters:
        `objObject` - object of Object class.
      Returns:
        boolean - shows success or failure of the comparison.