/*******************************************************************************
 *  Copyright 2017 Centre for Development of Advanced Computing(C-DAC), Pune
 *  
 *  Licensed under the Apache License, Version 2.0 (the "License");
 *  you may not use this file except in compliance with the License.
 *  You may obtain a copy of the License at
 *  
 *    http://www.apache.org/licenses/LICENSE-2.0
 *  
 *  Unless required by applicable law or agreed to in writing, software
 *  distributed under the License is distributed on an "AS IS" BASIS,
 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *  See the License for the specific language governing permissions and
 *  limitations under the License.
 *******************************************************************************/
package cdac.medinfo.sdk.hl7282.baselibs.segments;

import cdac.medinfo.sdk.hl7282.baselibs.CNE;
import cdac.medinfo.sdk.hl7282.baselibs.CWE;
import cdac.medinfo.sdk.hl7282.baselibs.DT;
import cdac.medinfo.sdk.hl7282.baselibs.DTM;
import cdac.medinfo.sdk.hl7282.baselibs.EI;
import cdac.medinfo.sdk.hl7282.baselibs.FN;
import cdac.medinfo.sdk.hl7282.baselibs.HD;
import cdac.medinfo.sdk.hl7282.baselibs.SI;
import cdac.medinfo.sdk.hl7282.baselibs.ST;
import cdac.medinfo.sdk.hl7282.baselibs.XCN;
import cdac.medinfo.sdk.hl7282.baselibs.XON;
import cdac.medinfo.sdk.hl7282.baselibs.XPN;
import cdac.medinfo.sdk.hl7282.commoninterface.IDataType;
import cdac.medinfo.sdk.hl7282.commoninterface.ISingleCollection;
import cdac.medinfo.sdk.hl7282.exceptions.FieldMissingException;
import cdac.medinfo.sdk.hl7282.exceptions.InvalidSegmentException;
import cdac.medinfo.sdk.hl7282.utils.EnumSegments;
import cdac.medinfo.sdk.hl7282.utils.SingleCollection;

/**
 * IAM - Patient Adverse Reaction Information Segment - Unique Identifier<p>
 * IAM segment contains person/patient adverse reaction information of various types.
 * Most of this information will be derived from user-defined tables.
 * Each IAM segment describes a single person/patient adverse reaction.
 * <p>Represents an HL7 IAM message segment. 
 * This segment has the following fields:</p><p>
 * IAM-1: Set ID - IAM (SI)<b>Required</b><br> 
 * IAM-2: Allergen Type Code (CWE)<b>Optional</b><br> 
 * IAM-3: Allergen Code/Mnemonic/Description (CWE)<b>Required</b><br> 
 * IAM-4: Allergy Severity Code (CWE)<b>Optional</b><br> 
 * IAM-5: Allergy Reaction Code (ST)<b>Optional</b><br> 
 * IAM-6: Allergy Action Code (CNE)<b>Required</b><br> 
 * IAM-7: Allergy Unique Identifier (EI)<b>Conditional</b><br> 
 * IAM-8: Action Reason (ST)<b>Optional</b><br> 
 * IAM-9: Sensitivity to Causative Agent Code (CWE)<b>Optional</b><br> 
 * IAM-10: Allergen Group Code/Mnemonic/Description (CWE)<b>Optional</b><br> 
 * IAM-11: Onset Date (DT)<b>Optional</b><br> 
 * IAM-12: Onset Date Text (ST)<b>Optional</b><br> 
 * IAM-13: Reported Date/Time (DTM)<b>Optional</b><br> 
 * IAM-14: Reported By (XPN)<b>Optional</b><br> 
 * IAM-15: Relationship to Patient Code (CWE)<b>Optional</b><br> 
 * IAM-16: Alert Device Code (CWE)<b>Optional</b><br> 
 * IAM-17: Allergy Clinical Status Code (CWE)<b>Optional</b><br> 
 * IAM-18: Statused by Person (XCN)<b>Optional</b><br> 
 * IAM-19: Statused by Organization (XON)<b>Optional</b><br> 
 * IAM-20: Statused at Date/Time (DTM)<b>Optional</b><br>
 * IAM-21: Inactivated By Person (XCN)<b>Optional</b><br>
 * IAM-22: Inactivated Date/Time at Date/Time (DTM)<b>Optional</b><br>
 * IAM-23: Initially Recorded By Person (XCN)<b>Optional</b><br>
 * IAM-24: Initially Recorded Date/Time at Date/Time (DTM)<b>Optional</b><br>
 * IAM-25: Modified By Person at Date/Time (XCN)<b>Optional</b><br>
 * IAM-26: Modified Date/Time (DTM)<b>Optional</b><br>
 * IAM-27: Clinician Identified Code (CWE)<b>Optional</b><br>
 * IAM-28: Initially Recorded By Organization (XON)<b>Optional</b><br>
 * IAM-29: Modified By Organization (XON)<b>Optional</b><br>
 * IAM-20: Inactivated By Organization (XON)<b>Optional</b><br><p>
 * This class provides mechanism to validate message against HL7 v 2.8.2 standard.
 * The class provides accessors & mutators for the elements mentioned above.
 * The class has validate method which validates Message against HL7 v 2.8.2 standard.
 *
 * <p>User can also create Segment through {@link SegmentFactory}
 */
 public class IAM extends Segment   
{

	


	/**
	 * Constructs the IAM segment.
	 */
	public IAM()
	{super(EnumSegments.HL7_SEG_IAM);
	}
	//Integer values used in getter/setter is unique item id defined 
	//for each attribute.

	/**
	 * Retrieves the Action Reason.
	 * This field contain the reason for the action indicated in the IAM-7 - Allergy Action Code field.
	 * @return String - actionReason
	 */
	public ST getActionReason() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1553);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (ST)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Alert Device Code.
	 * This field describes any type of allergy alert device the patient may be carrying or wearing.  
	 * @return CWE - alertDeviceCode
	 */
	public CWE getAlertDeviceCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1561);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergen Code Mnemonic Desc.
	 * This field uniquely identify a particular allergen.
	 * @return CWE - allergenCodeMnemonicDesc
	 */
	public CWE getAllergenCodeMnemonicDesc()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(205);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergen Grp Code Mnemonic Desc.
	 * This field contains the code, mnemonic, or description used to 
	 * uniquely identify an allergen group when both a detailed allergy 
	 * @return CWE - allergenGrpCodeMnemonicDesc
	 */
	public CWE getAllergenGrpCodeMnemonicDesc()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1555);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergen Type Code.
	 * This field indicates a general allergy category (drug, food, pollen, etc.).  
	 * @return CWE - allergenTypeCode
	 */
	public CWE getAllergenTypeCode() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(204);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergy Action Code.
	 * This field contains a code defining the status of the record.  
	 * @return CNE - allergyActionCode
	 */
	public CNE getAllergyActionCode() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1551);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CNE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergy Clinical Status Code.
	 * This field indicates the verification status for the allergy. 
	 * @return CWE - allergyClinicalStatusCode
	 */
	public CWE getAllergyClinicalStatusCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1562);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergy Reaction Code.
	 * This field identify the specific allergic reaction that is documented. 
	 * @return ISingleCollection<ST> - allergyReactionCode
	 */
	public ISingleCollection<ST> getAllergyReactionCode() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(207);
		ISingleCollection<ST> objDataList = new SingleCollection<ST>();
		if(objDataCollection != null && objDataCollection.size() != 0)
		{
			for(IDataType objDataType : objDataCollection)
			{
				ST objST = (ST)objDataType;
				objDataList.add(objST);
			}
		}

		return objDataList;
	}

	/**
	 * Retrieves the Allergy Severity Code.
	 * This field indicates the general severity of the allergy.  
	 * @return CWE - allergySeverityCode
	 */
	public CWE getAllergySeverityCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(206);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Allergy Unique Identifier.
	 * This field contains a value that uniquely identifies a single allergy for a person. 
	 * @return EI - allergyUniqueIdentifier
	 */
	public EI getAllergyUniqueIdentifier() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1552);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (EI)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Onset Date.
	 * This field contains the actual date of the first reaction.
	 * @return String - onsetDate
	 */
	public DT getOnsetDate()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1556);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DT)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Onset Date Text.
	 * This field contains a text description of the time period of the first reaction when an exact date is not known.
	 * @return String - onsetDateText
	 */
	public ST getOnsetDateText() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1557);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (ST)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Relationship Patient Code.
	 * This field contains the personal relationship that the person reporting the allergy has to the patient.
	 * @return CWE - relationshipPatientCode
	 */
	public CWE getRelationshipPatientCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1560);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Clinician Identified Code.
	 * @return CWE - clinician Identified Code
	 */
	public CWE getClinicianIdentifiedCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2300);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Reported By.
	 * This field contains the name of the person reporting the 
	 * allergy to a caregiver at the time reported in IAM-14 - Reported Date/Time.
	 * @return XPN - reportedBy
	 */
	public XPN getReportedBy() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1559);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XPN)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Reported Date Time.
	 * This field contains the date/time the allergy is reported to a caregiver.
	 * @return DTM - reportedDateTime
	 */
	public DTM getReportedDateTime() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1558);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DTM)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Sensitivity Causative Agent Code.
	 * This field contains the reason why the patient should not be exposed to a substance. 
	 * @return CE - sensitivityCausativeAgentCode
	 */
	public CWE getSensitivityCausativeAgentCode()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1554);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (CWE)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Set ID IAM.
	 * This field contains the number that identifies this transaction.  
	 * @return String - setID_IAM
	 */
	public SI getSetID_IAM()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1612);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (SI)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Statused Date Time.
	 * @return DTM - statusedDateTime
	 */
	public DTM getStatusedDateTime() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1565);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DTM)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Inactivated Date Time.
	 * @return DTM - inactivatedDateTime
	 */
	public DTM getInactivatedDateTime() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2295);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DTM)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the InitiallyRecordedDateTime.
	 * @return DTM - initiallyRecordedDateTime
	 */
	public DTM getInitiallyRecordedDateTime() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2297);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DTM)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the ModifiedDateTime.
	 * @return DTM - modifiedDateTime
	 */
	public DTM getModifiedDateTime() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2299);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (DTM)objDataCollection.elementAt(0);
		else
			return null;
	}
	/**
	 * Retrieves the Statused Organization.
	 * This field contains the name of the organization providing the update to the allergy.
	 * @return XON - statusedOrganization
	 */
	public XON getStatusedOrganization() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1564);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XON)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Initially Recorded By Organization
	 * @return XON - initiallyRecordedOrganization
	 */
	public XON getInitiallyRecordedOrganization() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(3293);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XON)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the ModifiedByOrganization
	 * @return XON - modifiedByOrganizationn
	 */
	public XON getModifiedByOrganization() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(3294);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XON)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Inactivated ByOrganization
	 * @return XON - inactivatedByOrganizationn
	 */
	public XON getInactivatedByOrganization() 
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(3295);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XON)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Retrieves the Statused Person.
	 * This field identify the provider who assigned the clinical status to the allergy. 
	 * @return XCN - statusedPerson
	 */
	public XCN getStatusedPerson()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(1563);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XCN)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Initially Recorded By Person.
	 * @return XCN - initially Recorded By Person.
	 */
	public XCN getInitiallyRecordedBYPerson()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2296);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XCN)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the ModifiedByPerson.
	 * @return XCN - modifiedByPerson
	 */
	public XCN getModifiedByPerson()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2298);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XCN)objDataCollection.elementAt(0);
		else
			return null;
	}
	
	/**
	 * Retrieves the Inactivated by Person.
	 * @return XCN - statusedPerson
	 */
	public XCN getInactivatedByPerson()
	{
		ISingleCollection<IDataType> objDataCollection =getDataType(2294);
		if(objDataCollection != null && objDataCollection.size() != 0) 
			return (XCN)objDataCollection.elementAt(0);
		else
			return null;
	}

	/**
	 * Set the Action Reason.
	 * This field contain the reason for the action indicated in the IAM-7 - Allergy Action Code field.
	 * @param strActionReason String value of the reason for the action indicated in the
	 * IAM-7 - Allergy Action Code field. 
	 */ 
	public void setActionReason (String strActionReason) 
	{
		ST actionReason  = (ST)getDataElement(1553);
		actionReason.setValue(strActionReason); 
		setActionReason(actionReason);

	} 

	/** Set the Action Reason.
	 * This field contain the reason for the action indicated in the IAM-7 - Allergy Action Code field.
	 * @param objactionReason object of Action Reason. 
	 */ 
	public void setActionReason(ST objactionReason)
	{
		setDataType(1553,objactionReason);
	}

	/**
	 * Set the Alert Device Code.
	 * This field describes any type of allergy alert device the patient may be carrying or wearing.  
	  * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	 
	public void setAlertDeviceCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE alertDeviceCode  = (CWE)getDataElement(1561);
		alertDeviceCode .setIdentifier(strIdentifier);
		alertDeviceCode .setText(strText);
		alertDeviceCode .setNameOfCodingSystem(strNameOfCodingSystem);
		alertDeviceCode .setAlternateIdentifier(strAlternateIdentifier);
		alertDeviceCode .setAlternateText(strAlternateText);
		alertDeviceCode .setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		alertDeviceCode .setCodingSystemVersionID(strCodingSystemVersionID);
		alertDeviceCode .setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		alertDeviceCode .setOriginalText(strOriginalText);
		alertDeviceCode .setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		alertDeviceCode .setSecondAlternateText(strSecondAlternateText);
		alertDeviceCode .setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		alertDeviceCode .setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		alertDeviceCode .setCodingSystemOID(strCodingSystemOID);
		alertDeviceCode .setValueSetOID(strValueSetOID);
		alertDeviceCode .setValueSetVersionID(strValueSetVersionID);
		alertDeviceCode .setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		alertDeviceCode .setAlternateValueSetOID(strAlternateValueSetOID);
		alertDeviceCode .setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		alertDeviceCode .setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		alertDeviceCode .setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		alertDeviceCode .setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setAlertDeviceCode(alertDeviceCode);

	} 

	/** Set the Alert Device Code.
	 * This field describes any type of allergy alert device the patient may be carrying or wearing.  
	 * @param objalertDeviceCode object of Alert Device Code.
	 */ 
	public void setAlertDeviceCode(CWE objalertDeviceCode)
	{
		setDataType(1561,objalertDeviceCode);
	}

	/**
	 * Set the Allergen Code Mnemonic Desc.
	 * This field uniquely identify a particular allergen.
	 * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */
	public void setAllergenCodeMnemonicDesc (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE allergenCodeMnemonicDesc  = (CWE)getDataElement(205);
		allergenCodeMnemonicDesc.setIdentifier(strIdentifier);
		allergenCodeMnemonicDesc.setText(strText);
		allergenCodeMnemonicDesc.setNameOfCodingSystem(strNameOfCodingSystem);
		allergenCodeMnemonicDesc.setAlternateIdentifier(strAlternateIdentifier);
		allergenCodeMnemonicDesc.setAlternateText(strAlternateText);
		allergenCodeMnemonicDesc.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		allergenCodeMnemonicDesc.setCodingSystemVersionID(strCodingSystemVersionID);
		allergenCodeMnemonicDesc.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		allergenCodeMnemonicDesc.setOriginalText(strOriginalText);
		allergenCodeMnemonicDesc.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		allergenCodeMnemonicDesc.setSecondAlternateText(strSecondAlternateText);
		allergenCodeMnemonicDesc.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		allergenCodeMnemonicDesc.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		allergenCodeMnemonicDesc.setCodingSystemOID(strCodingSystemOID);
		allergenCodeMnemonicDesc.setValueSetOID(strValueSetOID);
		allergenCodeMnemonicDesc.setValueSetVersionID(strValueSetVersionID);
		allergenCodeMnemonicDesc.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		allergenCodeMnemonicDesc.setAlternateValueSetOID(strAlternateValueSetOID);
		allergenCodeMnemonicDesc.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		allergenCodeMnemonicDesc.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		allergenCodeMnemonicDesc.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		allergenCodeMnemonicDesc.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID);
		setAllergenCodeMnemonicDesc(allergenCodeMnemonicDesc);

	} 

	/** Set the Allergen Code Mnemonic Desc.
	 * This field uniquely identify a particular allergen.
	 * @param strNameOfAlternateCodingSystem object of Allergen Code Mnemonic Desc.
	 */ 
	public void setAllergenCodeMnemonicDesc(CWE objallergenCodeMnemonicDesc)
	{
		setDataType(205,objallergenCodeMnemonicDesc);

	}

	/**
	 * Set the Allergen Grp Code Mnemonic Desc.
	 * This field contains the code, mnemonic, or description used to 
	 * uniquely identify an allergen group when both a detailed allergy  
	  * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	
	public void setAllergenGrpCodeMnemonicDesc  (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE allergenGrpCodeMnemonicDesc  = (CWE)getDataElement(1555);
		allergenGrpCodeMnemonicDesc.setIdentifier(strIdentifier);
		allergenGrpCodeMnemonicDesc.setText(strText);
		allergenGrpCodeMnemonicDesc.setNameOfCodingSystem(strNameOfCodingSystem);
		allergenGrpCodeMnemonicDesc.setAlternateIdentifier(strAlternateIdentifier);
		allergenGrpCodeMnemonicDesc.setAlternateText(strAlternateText);
		allergenGrpCodeMnemonicDesc.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		allergenGrpCodeMnemonicDesc.setCodingSystemVersionID(strCodingSystemVersionID);
		allergenGrpCodeMnemonicDesc.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		allergenGrpCodeMnemonicDesc.setOriginalText(strOriginalText);
		allergenGrpCodeMnemonicDesc.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		allergenGrpCodeMnemonicDesc.setSecondAlternateText(strSecondAlternateText);
		allergenGrpCodeMnemonicDesc.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		allergenGrpCodeMnemonicDesc.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		allergenGrpCodeMnemonicDesc.setCodingSystemOID(strCodingSystemOID);
		allergenGrpCodeMnemonicDesc.setValueSetOID(strValueSetOID);
		allergenGrpCodeMnemonicDesc.setValueSetVersionID(strValueSetVersionID);
		allergenGrpCodeMnemonicDesc.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		allergenGrpCodeMnemonicDesc.setAlternateValueSetOID(strAlternateValueSetOID);
		allergenGrpCodeMnemonicDesc.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		allergenGrpCodeMnemonicDesc.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		allergenGrpCodeMnemonicDesc.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		allergenGrpCodeMnemonicDesc.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setAllergenGrpCodeMnemonicDesc(allergenGrpCodeMnemonicDesc);

	} 

	/** Set the Allergen Grp Code Mnemonic Desc.
	 * This field contains the code, mnemonic, or description used to 
	 * uniquely identify an allergen group when both a detailed allergy  
	 * @param objallergenGrpCodeMnemonicDesc object of Allergen Grp Code Mnemonic Desc.
	 */ 
	public void setAllergenGrpCodeMnemonicDesc(CWE objallergenGrpCodeMnemonicDesc)
	{
		setDataType(1555,objallergenGrpCodeMnemonicDesc);
	}

	/**
	 * Set the Allergen Type Code.
	 * This field indicates a general allergy category (drug, food, pollen, etc.).  
	  * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	 
	public void setAllergenTypeCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE allergenTypeCode  = (CWE)getDataElement(204);
		allergenTypeCode.setIdentifier(strIdentifier);
		allergenTypeCode.setText(strText);
		allergenTypeCode.setNameOfCodingSystem(strNameOfCodingSystem);
		allergenTypeCode.setAlternateIdentifier(strAlternateIdentifier);
		allergenTypeCode.setAlternateText(strAlternateText);
		allergenTypeCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		allergenTypeCode.setCodingSystemVersionID(strCodingSystemVersionID);
		allergenTypeCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		allergenTypeCode.setOriginalText(strOriginalText);
		allergenTypeCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		allergenTypeCode.setSecondAlternateText(strSecondAlternateText);
		allergenTypeCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		allergenTypeCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		allergenTypeCode.setCodingSystemOID(strCodingSystemOID);
		allergenTypeCode.setValueSetOID(strValueSetOID);
		allergenTypeCode.setValueSetVersionID(strValueSetVersionID);
		allergenTypeCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		allergenTypeCode.setAlternateValueSetOID(strAlternateValueSetOID);
		allergenTypeCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		allergenTypeCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		allergenTypeCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		allergenTypeCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setAllergenTypeCode(allergenTypeCode);

	} 

	/** Set the Allergen Type Code.
	 * This field indicates a general allergy category (drug, food, pollen, etc.).  
	 * @param objallergenTypeCode object of Allergen Type Code.
	 */ 
	public void setAllergenTypeCode(CWE objallergenTypeCode)
	{
		setDataType(204,objallergenTypeCode);

	}

	/**
	 * Set the Allergy Action Code.
	 * This field contains a code defining the status of the record.
	 * @param strIdentifier Specifies sequence of characters (the code) that uniquely identifies
	 * 						 the item being referenced by the CNE.
	 * @param strText Specifies descriptive or textual name of the identifier, e.g., myocardial infarction 
	 * @param strNameOfCodingSystem Specifies the coding scheme being used in the identifier component. 
	 * @param strAlternateIdentifier Specifies the local or user seen code as described. 
	 * @param strAlternateText Specifies descriptive or textual name of the alternate identifier.  
	 * @param strNameOfAlternateCodingSystem Specifies the coding scheme being used in the alternate identifier 
	 * 											component.  
	 * @param strCodingSystemVersionID Specifies the version ID for the coding system. 
	 * @param strAlternateCodingSystemVersionID Specifies the version ID for the coding system .
	 * @param strOriginalText Specifies the original text that was available to an automated process or a human 
	 * 							before a specific code was assigned.
	 * @param strSecondAlternateIdentifier Specifies a sequence of characters that uniquely identifies the second alternate code
	 * @param strSecondAlternateText Specifies a the textual information of the second alternate code
	 * @param strNameOfSecondAltenateCodingSystem Specifies the second coding scheme being used in the identifier component.
	 * @param strSecondAlternateCodingSystemVersionID Specifies version ID of Second alternative coding system.
	 * @param strCodingSystemOID contains the ISO Object identifier for the coding system.
	 * @param strValueSetOID contains the value set from which CNE-1 is obtained 
	 * @param strValueSetVersionID contains the version of the value set identified by CNE-15. 
	 * @param strAlternateCodingSystemOID contains the ISO Object identifier for the alternate coding system
	 * @param strAlternateValueSetOID contains the value set from which CNE-4 is obtained
	 * @param strAlternateValueSetVersionID contains the version of the value set identified by CNE-18. 
	 * @param strSecondAlternateCodingSystemOID contains the value set from which CNE-12 is obtained
	 * @param strSecondAlternateValueSetOID contains the value set from which CNE-10 is obtained
	 * @param strSecondAlternateValueSetVersionID contains the version of the value set identified by CNE-21. 
	 */ 
	public void setAllergyActionCode (String strIdentifier,String strText,String strNameOfCodingSystem,String strAlternateIdentifier,
			String strAlternateText,String strNameOfAlternateCodingSystem,String strCodingSystemVersionID,
			String strAlternateCodingSystemVersionID,String strOriginalText, String strSecondAlternateIdentifier, String strSecondAlternateText,
			String strNameOfSecondAltenateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, 
			String strValueSetOID, String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID,
			String strAlternateValueSetVersionID, String strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID,
			String strSecondAlternateValueSetVersionID)
	{
		CNE allergyActionCode  = (CNE)getDataElement(1551);
		allergyActionCode.setIdentifier(strIdentifier);
		allergyActionCode.setText(strText);
		allergyActionCode.setNameOfCodingSystem(strNameOfCodingSystem);
		allergyActionCode.setAlternateIdentifier(strAlternateIdentifier);
		allergyActionCode.setAlternateText(strAlternateText);
		allergyActionCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem);
		allergyActionCode.setCodingSystemVersionID(strCodingSystemVersionID);
		allergyActionCode.setAlternateCodingSystemVersionID(strAlternateCodingSystemVersionID);
		allergyActionCode.setOriginalText(strOriginalText); 
		allergyActionCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		allergyActionCode.setSecondAlternateText(strSecondAlternateText);
		allergyActionCode.setNameofSecondAlternateCodingSystem(strNameOfSecondAltenateCodingSystem);
		allergyActionCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		allergyActionCode.setCodingSystemOID(strCodingSystemOID);
		allergyActionCode.setValueSetOID(strValueSetOID);
		allergyActionCode.setValueSetVersionID(strValueSetVersionID);
		allergyActionCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		allergyActionCode.setAlternateValueSetOID(strAlternateValueSetOID);
		allergyActionCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		allergyActionCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		allergyActionCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		allergyActionCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID);
		setAllergyActionCode(allergyActionCode);

	} 

	/** Set the Allergy Action Code.
	 * This field contains a code defining the status of the record.
	 * @param objallergyActionCode object of Allergy Action Code.
	 */ 
	public void setAllergyActionCode(CNE objallergyActionCode)
	{
		setDataType(1551,objallergyActionCode);
	}

	/**
	 * Set the Allergy Clinical Status Code.
	 * This field indicates the verification status for the allergy.  
	* @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	 
	public void setAllergyClinicalStatusCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE allergyClinicalStatusCode  = (CWE)getDataElement(1562);
		allergyClinicalStatusCode.setIdentifier(strIdentifier);
		allergyClinicalStatusCode.setText(strText);
		allergyClinicalStatusCode.setNameOfCodingSystem(strNameOfCodingSystem);
		allergyClinicalStatusCode.setAlternateIdentifier(strAlternateIdentifier);
		allergyClinicalStatusCode.setAlternateText(strAlternateText);
		allergyClinicalStatusCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		allergyClinicalStatusCode.setCodingSystemVersionID(strCodingSystemVersionID);
		allergyClinicalStatusCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		allergyClinicalStatusCode.setOriginalText(strOriginalText);
		allergyClinicalStatusCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		allergyClinicalStatusCode.setSecondAlternateText(strSecondAlternateText);
		allergyClinicalStatusCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		allergyClinicalStatusCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		allergyClinicalStatusCode.setCodingSystemOID(strCodingSystemOID);
		allergyClinicalStatusCode.setValueSetOID(strValueSetOID);
		allergyClinicalStatusCode.setValueSetVersionID(strValueSetVersionID);
		allergyClinicalStatusCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		allergyClinicalStatusCode.setAlternateValueSetOID(strAlternateValueSetOID);
		allergyClinicalStatusCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		allergyClinicalStatusCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		allergyClinicalStatusCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		allergyClinicalStatusCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID);
		setAllergyClinicalStatusCode(allergyClinicalStatusCode);

	} 

	/** Set the Allergy Clinical Status Code.
	 * This field indicates the verification status for the allergy.  
	 * @param objallergyClinicalStatusCode object of Allergy Clinical Status Code.
	 */ 
	public void setAllergyClinicalStatusCode(CWE objallergyClinicalStatusCode)
	{
		setDataType(1562,objallergyClinicalStatusCode);
	}

	/**
	 * Set the Allergy Reaction Code.
	 * This field identify the specific allergic reaction that is documented.  
	 * @param strAllergyReactionCode Contains specific allergic reaction that was documented.  
	 */ 
	public void addAllergyReactionCode (String strAllergyReactionCode) 
	{
		ST tempAllergyReactionCode  = (ST)getDataElement(207);
		tempAllergyReactionCode.setValue(strAllergyReactionCode); 
		addAllergyReactionCode(tempAllergyReactionCode);

	} 

	/** Set the Allergy Reaction Code.
	 * This field identify the specific allergic reaction that is documented.  
	 * @param objtempAllergyReactionCode object of Allergy Reaction Code.  
	 */ 
	public void addAllergyReactionCode(ST objtempAllergyReactionCode)
	{
		addDataType(207,objtempAllergyReactionCode);

	}	
	/**
	 * Set the Allergy Reaction Code.
	 * @param objAllergyReactionCode List of Allergy Reaction Code
	 */	
	@SuppressWarnings("unchecked")
	public void setAllergyReactionCode(ISingleCollection<ST> objAllergyReactionCode)
	{
		ISingleCollection<IDataType> objCollection = null;
		ISingleCollection<?> objUnknownCollection = (ISingleCollection<?>)objAllergyReactionCode;
		objCollection = (ISingleCollection<IDataType>)objUnknownCollection;
		setDataType(207,objCollection);
	}

	/**
	 * Set the Allergy Severity Code.
	 * This field indicates the general severity of the allergy.  
	 * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	
	public void setAllergySeverityCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE tempAllergyReactionCode  = (CWE)getDataElement(206);
		tempAllergyReactionCode.setIdentifier(strIdentifier);
		tempAllergyReactionCode.setText(strText);
		tempAllergyReactionCode.setNameOfCodingSystem(strNameOfCodingSystem);
		tempAllergyReactionCode.setAlternateIdentifier(strAlternateIdentifier);
		tempAllergyReactionCode.setAlternateText(strAlternateText);
		tempAllergyReactionCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		tempAllergyReactionCode.setCodingSystemVersionID(strCodingSystemVersionID);
		tempAllergyReactionCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		tempAllergyReactionCode.setOriginalText(strOriginalText);
		tempAllergyReactionCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		tempAllergyReactionCode.setSecondAlternateText(strSecondAlternateText);
		tempAllergyReactionCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		tempAllergyReactionCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		tempAllergyReactionCode.setCodingSystemOID(strCodingSystemOID);
		tempAllergyReactionCode.setValueSetOID(strValueSetOID);
		tempAllergyReactionCode.setValueSetVersionID(strValueSetVersionID);
		tempAllergyReactionCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		tempAllergyReactionCode.setAlternateValueSetOID(strAlternateValueSetOID);
		tempAllergyReactionCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		tempAllergyReactionCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		tempAllergyReactionCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		tempAllergyReactionCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID);
		setAllergySeverityCode(tempAllergyReactionCode);

	} 

	/** Set the Allergy Severity Code.
	 * This field indicates the general severity of the allergy.  
	 * @param objtempAllergyReactionCode object of Allergy Severity Code.
	 */ 
	public void setAllergySeverityCode(CWE objtempAllergyReactionCode)
	{
		setDataType(206,objtempAllergyReactionCode);

	}

	/**
	 * Set the Allergy Unique Identifier.
	 * This field contains a value that uniquely identifies a single allergy for a person.  
	 * @param strEntityIdentifier Specifies defined by a hierarchic designator, represented by components 2 through 4.
	 * 								[Reference Section 2.A.33, "HD - hierarchic designator".] 
	 * @param strNamespaceId Specifies  the HL7 identifier for the user-defined table of values for this component.
	 * 						   [Refer to User-defined Table 0363 - Assigning authority] 	 
	 * @param strUniversalId Specifies string formatted according to the scheme defined by the component, 
	 * 							<universal ID type> (UID type). 
	 * @param strUniversalIdType Specifies  the interpretation of the second component of the HD. 
	 */ 
	public void setAllergyUniqueIdentifier (String strEntityIdentifier,String strNamespaceId,
			String strUniversalId,String strUniversalIdType)
	{
		EI allergyUniqueIdentifier  = (EI)getDataElement(1552);
		allergyUniqueIdentifier.setEntityIdentifier(strEntityIdentifier);
		allergyUniqueIdentifier.setNamespaceId(strNamespaceId);
		allergyUniqueIdentifier.setUniversalId(strUniversalId);
		allergyUniqueIdentifier.setUniversalIdType(strUniversalIdType); 
		setAllergyUniqueIdentifier(allergyUniqueIdentifier);

	} 

	/** Set the Allergy Unique Identifier.
	 * This field contains a value that uniquely identifies a single allergy for a person.  
	 * @param objallergyUniqueIdentifier object of Allergy Unique Identifier.
	 */ 
	public void setAllergyUniqueIdentifier(EI objallergyUniqueIdentifier)
	{
		setDataType(1552,objallergyUniqueIdentifier);

	}

	/**
	 * Set the Onset Date.
	 * This field contains the actual date of the first reaction.
	 * @param strOnsetDate Contains the actual date of the first reaction.
	 */ 
	public void setOnsetDate (String strOnsetDate) 
	{
		DT onsetDate  = (DT)getDataElement(1556);
		onsetDate.setValue(strOnsetDate); 
		setOnsetDate(onsetDate);

	} 

	/** Set the Onset Date.
	 * This field contains the actual date of the first reaction.
	 * @param objonsetDate object of Onset Date.
	 */ 
	public void setOnsetDate(DT objonsetDate)
	{
		setDataType(1556,objonsetDate);
	}

	/**
	 * Set the Onset Date Text.
	 * This field contains a text description of the time period of the first reaction when an exact date is not known.
	 * @param strOnsetDateText Contains a text description of the time period of
	 * 							 the first reaction when an exact date is not known.
	 */ 
	public void setOnsetDateText (String strOnsetDateText) 
	{
		ST onsetDateText  = (ST)getDataElement(1557);
		onsetDateText.setValue(strOnsetDateText); 
		setOnsetDateText(onsetDateText);

	} 

	/** Set the Onset Date Text.
	 * This field contains a text description of the time period of the first reaction when an exact date is not known.
	 * @param objonsetDateText object of Onset Date Text.
	 */ 
	public void setOnsetDateText(ST objonsetDateText)
	{
		setDataType(1557,objonsetDateText);
	}

	/**
	 * Set the Relationship Patient Code.
	 * This field contains the personal relationship that the person reporting the allergy has to the patient. 
	* @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */
	public void setRelationshipPatientCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE relationshipPatientCode  = (CWE)getDataElement(1560);
		relationshipPatientCode.setIdentifier(strIdentifier);
		relationshipPatientCode.setText(strText);
		relationshipPatientCode.setNameOfCodingSystem(strNameOfCodingSystem);
		relationshipPatientCode.setAlternateIdentifier(strAlternateIdentifier);
		relationshipPatientCode.setAlternateText(strAlternateText);
		relationshipPatientCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		relationshipPatientCode.setCodingSystemVersionID(strCodingSystemVersionID);
		relationshipPatientCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		relationshipPatientCode.setOriginalText(strOriginalText);
		relationshipPatientCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		relationshipPatientCode.setSecondAlternateText(strSecondAlternateText);
		relationshipPatientCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		relationshipPatientCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		relationshipPatientCode.setCodingSystemOID(strCodingSystemOID);
		relationshipPatientCode.setValueSetOID(strValueSetOID);
		relationshipPatientCode.setValueSetVersionID(strValueSetVersionID);
		relationshipPatientCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		relationshipPatientCode.setAlternateValueSetOID(strAlternateValueSetOID);
		relationshipPatientCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		relationshipPatientCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		relationshipPatientCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		relationshipPatientCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setRelationshipPatientCode(relationshipPatientCode);

	} 

	/** Set the Relationship Patient Code.
	 * This field contains the personal relationship that the person reporting the allergy has to the patient. 
	 * @param objrelationshipPatientCode object of Relationship Patient Code.
	 */ 
	public void setRelationshipPatientCode(CWE objrelationshipPatientCode)
	{
		setDataType(1560,objrelationshipPatientCode);

	}

	/**
	 * Set the Clinician Identified Code.
	* @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */
	public void setClinicianIdentifiedCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE clinicianIdentifiedCode  = (CWE)getDataElement(2300);
		clinicianIdentifiedCode.setIdentifier(strIdentifier);
		clinicianIdentifiedCode.setText(strText);
		clinicianIdentifiedCode.setNameOfCodingSystem(strNameOfCodingSystem);
		clinicianIdentifiedCode.setAlternateIdentifier(strAlternateIdentifier);
		clinicianIdentifiedCode.setAlternateText(strAlternateText);
		clinicianIdentifiedCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		clinicianIdentifiedCode.setCodingSystemVersionID(strCodingSystemVersionID);
		clinicianIdentifiedCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		clinicianIdentifiedCode.setOriginalText(strOriginalText);
		clinicianIdentifiedCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		clinicianIdentifiedCode.setSecondAlternateText(strSecondAlternateText);
		clinicianIdentifiedCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		clinicianIdentifiedCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		clinicianIdentifiedCode.setCodingSystemOID(strCodingSystemOID);
		clinicianIdentifiedCode.setValueSetOID(strValueSetOID);
		clinicianIdentifiedCode.setValueSetVersionID(strValueSetVersionID);
		clinicianIdentifiedCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		clinicianIdentifiedCode.setAlternateValueSetOID(strAlternateValueSetOID);
		clinicianIdentifiedCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		clinicianIdentifiedCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		clinicianIdentifiedCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		clinicianIdentifiedCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setClinicianIdentifiedCode(clinicianIdentifiedCode);

	} 

	/** Set the Clinician Identified Code.
	 * @param objclinicianIdentifiedCode object of Clinician Identified Allergen Code.
	 */ 
	public void setClinicianIdentifiedCode(CWE objclinicianIdentifiedCode)
	{
		setDataType(2300,objclinicianIdentifiedCode);

	}
	
	/**
	 * Set the Reported By.
	 * This field contains the name of the person reporting the 
	 * allergy to a caregiver at the time reported in IAM-14 - Reported Date/Time.
	  * @param objFamilyName Specifies the surname of a person. 
	 * @param strGivenName Specifies First name.
	 * @param strSecondAndFurtherGivenNamesOrInitialsThereof Specifies multiple middle names that may be included by separating them with spaces.
	 * @param strSuffix Used to specify a name suffix (e.g., Jr. or III).
	 * @param strPrefix Used to specify a name prefix (e.g., Dr.).
	 * @param strNameTypeCode Specifies a code that represents the type of name. Suggested values are A,B,C,D,I,L,M,N,P,R,S,T,U...[Refer table 0200.]
	 * @param strNameRepresentationCode Specifies representations of the same name/address Suggested values are I,A,P [Refer table 0465] 
	 * @param objNameContext Designates the context in which a name is used. [Refer User-defined Table 0448 ]
	 * @param strNameAssemblyOrder Specifies a code that represents the preferred display order of the components of this person name. Suggested values are G,F[Refer table 0444.]
	 * @param objEffectiveDate Specifies the first date, if known, on which the address is valid and active.
	 * @param objExpirationDate Specifies the last date, if known, on which the address is valid and active.
	 * @param strProfessionalSuffix Used to specify an abbreviation, or a string of abbreviations, denoting qualifications that support the person's profession, (e.g., licenses). 
	 * @param strCalledBy Used to specify the called name.
	 */ 
	public void setReportedBy (FN objFamilyName, String strGivenName, String strSecondAndFurtherGivenNamesOrInitialsThereof, 
			String strSuffix, String strPrefix, String strNameTypeCode, String strNameRepresentationCode, 
			CWE objNameContext, String strNameAssemblyOrder, DTM objEffectiveDate,
			DTM objExpirationDate, String strProfessionalSuffix, String strCalledBy)
	{
		XPN reportedBy = (XPN)getDataElement(1559);
		reportedBy.setFamilyName(objFamilyName);
		reportedBy.setGivenName(strGivenName);
		reportedBy.setSecondNameOrInitials(strSecondAndFurtherGivenNamesOrInitialsThereof);
		reportedBy.setSuffix(strSuffix);
		reportedBy.setPrefix(strPrefix);
//		reportedBy.setDegree(strDegree);
		reportedBy.setNameTypeCode(strNameTypeCode);
		reportedBy.setNameRepresentationCode(strNameRepresentationCode);
		reportedBy.setNameContext(objNameContext);
//		reportedBy.setNameValidityRange(objNameValidityRange);
		reportedBy.setNameAssemblyOrder(strNameAssemblyOrder);
		reportedBy.setEffectiveDate(objEffectiveDate);
		reportedBy.setExpirationDate(objExpirationDate);
		reportedBy.setProfessionalSuffix(strProfessionalSuffix); 
		reportedBy.setCalledBy(strCalledBy); 
		setReportedBy(reportedBy);

	} 

	/** 
	 * Sets the Reported By
	 * @param objreportedBy object of Reported By. 
	 */ 
	public void setReportedBy(XPN objreportedBy)
	{
		setDataType(1559,objreportedBy);

	}

	/**
	 * Set the Reported Date Time.
	 * This field contains the date/time the allergy is reported to a caregiver.
	 * @param strDateTimePlannedEvent This field contains the date/time that the event is planned. 
	 */ 
	public void setReportedDateTime (String strDateTimePlannedEvent)  
	{
		DTM reportedDateTime  = (DTM)getDataElement(1558);
		reportedDateTime.setValue(strDateTimePlannedEvent);
		setReportedDateTime(reportedDateTime);

	} 

	/** 
	 * Sets the Reported Date Time.
	 * @param objreportedDateTime object of Reported Date Time.
	 */ 
	public void setReportedDateTime(DTM objreportedDateTime)
	{
		setDataType(1558,objreportedDateTime);
	}

	/**
	 * Set the Sensitivity Causative Agent Code.
	 * This field contains the reason why the patient should not be exposed to a substance.  
	  * @param strIdentifier Specifies of characters (the code) that uniquely identifies the item being referenced. 
	 * @param strText Specifies The descriptive or textual name of the identifier, e.g., myocardial infarction. 
	 * @param strNameOfCodingSystem Identifies the coding scheme being used in the identifier component.
	 * @param strAlternateIdentifier Specifies an alternate sequence of characters (the code) that uniquely identifies the item being referenced.
	 * @param strAlternateText Specifies the descriptive or textual name of the alternate identifier. See usage note in section introduction.
	 * @param strNameOfAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component. 
	 * @param strCodingSystemVersionID A sequence of characters that uniquely identifies a second alternate code.
	 * @param strAlternateCodingSystemVersionId This component carries the version for the coding system identified by components 4-6.
	 * @param strOriginalText The text as seen and/or selected by the user who entered the data.
	 * @param strSecondAlternateIdentifier A sequence of characters that uniquely identifies a second alternate code.
	 * @param strSecondAlternateText The descriptive or textual name of the alternate identifier.
	 * @param strNameofSecondAlternateCodingSystem Identifies the coding scheme being used in the alternate identifier component.
	 * @param strSecondAlternateCodingSystemVersionID This component carries the version for the coding system identified by components 10-12.
	 * @param strCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.3.
	 * @param strValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.1 is obtained.
	 * @param strValueSetVersionID This component carries the version for the value set identified by CWE.15. The version is a date. The date is the date/time that the value set being used was published.
	 * @param strAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.6.
	 * @param strAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.4 is obtained.
	 * @param strAlternateValueSetVersionID This component carries the version for the value set identified by CWE.18. The version is a date.
	 * @param strSecondAlternateCodingSystemOID This component contains the ISO Object Identifier (OID) for the coding system or value set named in CWE.12.
	 * @param strSecondAlternateValueSetOID This component contains the ISO Object Identifier (OID) to allow identification of the value set from which the value in CWE.10 is obtained.
	 * @param strSecondAlternateValueSetVersionID This component carries the version for the value set identified by CWE.21. The version is a date.
	 */	
	public void setSensitivityCausativeAgentCode (String strIdentifier,String strText,String strNameOfCodingSystem,
			String strAlternateIdentifier,String strAlternateText,String strNameOfAlternateCodingSystem, String strCodingSystemVersionID, String 				strAlternateCodingSystemVersionId,
			String strOriginalText, String  strSecondAlternateIdentifier, String strSecondAlternateText, 
			String strNameofSecondAlternateCodingSystem, String strSecondAlternateCodingSystemVersionID, String strCodingSystemOID, String strValueSetOID,
			String strValueSetVersionID, String strAlternateCodingSystemOID, String strAlternateValueSetOID, String strAlternateValueSetVersionID,
			String  strSecondAlternateCodingSystemOID, String strSecondAlternateValueSetOID, String strSecondAlternateValueSetVersionID)
	{
		CWE sensitivityCausativeAgentCode  = (CWE)getDataElement(1554);
		sensitivityCausativeAgentCode.setIdentifier(strIdentifier);
		sensitivityCausativeAgentCode.setText(strText);
		sensitivityCausativeAgentCode.setNameOfCodingSystem(strNameOfCodingSystem);
		sensitivityCausativeAgentCode.setAlternateIdentifier(strAlternateIdentifier);
		sensitivityCausativeAgentCode.setAlternateText(strAlternateText);
		sensitivityCausativeAgentCode.setNameOfAlternateCodingSystem(strNameOfAlternateCodingSystem); 
		sensitivityCausativeAgentCode.setCodingSystemVersionID(strCodingSystemVersionID);
		sensitivityCausativeAgentCode.setAlternateCodingSystemVersionId(strAlternateCodingSystemVersionId);
		sensitivityCausativeAgentCode.setOriginalText(strOriginalText);
		sensitivityCausativeAgentCode.setSecondAlternateIdentifier(strSecondAlternateIdentifier);
		sensitivityCausativeAgentCode.setSecondAlternateText(strSecondAlternateText);
		sensitivityCausativeAgentCode.setNameofSecondAlternateCodingSystem(strNameofSecondAlternateCodingSystem);
		sensitivityCausativeAgentCode.setSecondAlternateCodingSystemVersionID(strSecondAlternateCodingSystemVersionID);
		sensitivityCausativeAgentCode.setCodingSystemOID(strCodingSystemOID);
		sensitivityCausativeAgentCode.setValueSetOID(strValueSetOID);
		sensitivityCausativeAgentCode.setValueSetVersionID(strValueSetVersionID);
		sensitivityCausativeAgentCode.setAlternateCodingSystemOID(strAlternateCodingSystemOID);
		sensitivityCausativeAgentCode.setAlternateValueSetOID(strAlternateValueSetOID);
		sensitivityCausativeAgentCode.setAlternateValueSetVersionID(strAlternateValueSetVersionID);
		sensitivityCausativeAgentCode.setSecondAlternateCodingSystemOID(strSecondAlternateCodingSystemOID);
		sensitivityCausativeAgentCode.setSecondAlternateValueSetOID(strSecondAlternateValueSetOID);
		sensitivityCausativeAgentCode.setSecondAlternateValueSetVersionID(strSecondAlternateValueSetVersionID); 
		setSensitivityCausativeAgentCode(sensitivityCausativeAgentCode);

	} 

	/** Set the Sensitivity Causative Agent Code.
	 * This field contains the reason why the patient should not be exposed to a substance.  
	 * @param objsensitivityCausativeAgentCode object of Sensitivity Causative Agent Code.
	 */ 
	public void setSensitivityCausativeAgentCode(CWE objsensitivityCausativeAgentCode)
	{
		setDataType(1554,objsensitivityCausativeAgentCode);
	}

	/**
	 * Set the Set ID IAM.
	 * This field contains the number that identifies this transaction.
	 * @param strSetID_IAM Contains  Segment-ID.
	 */ 
	public void setSetID_IAM (String strSetID_IAM) 
	{
		SI setID_IAM  = (SI)getDataElement(1612);

		setID_IAM.setValue(strSetID_IAM); 
		setSetID_IAM(setID_IAM);


	} 

	/** Set the Set ID IAM.
	 * This field contains the number that identifies this transaction.
	 * @param objsetID_IAM object of Set ID IAM.
	 */ 
	public void setSetID_IAM(SI objsetID_IAM)
	{
		setDataType(1612,objsetID_IAM);


	}

	/**
	 * Set the Statused Date Time.
	 * @param strDateTimePlannedEvent This field contains the date/time that the event is planned. 
	 */
	public void setStatusedDateTime (String strDateTimePlannedEvent) 
	{
		DTM statusedDateTime  = (DTM)getDataElement(1565);
		statusedDateTime.setValue(strDateTimePlannedEvent);
		setStatusedDateTime(statusedDateTime);


	} 

	/** Set the Statused Date Time.
	 * @param strTime Specifies a point in time using a 24-hour clock notation. 
	 * @param objstatusedDateTime object of Statused Date Time.
	 */ 
	public void setStatusedDateTime(DTM objstatusedDateTime)
	{
		setDataType(1565,objstatusedDateTime);
	}

	/**
	 * Set the Inactivated Date Time.
	 * @param strDateTimePlannedEvent This field contains the date/time that the event is planned. 
	 */
	public void setInactivatedDateTime (String strDateTimePlannedEvent) 
	{
		DTM inactivatedDateTime  = (DTM)getDataElement(2295);
		inactivatedDateTime.setValue(strDateTimePlannedEvent);
		setInactivatedDateTime(inactivatedDateTime);


	} 

	/** Set the Inactivated Date Time.
	 * @param strTime Specifies a point in time using a 24-hour clock notation. 
	 * @param objstatusedDateTime object of Statused Date Time.
	 */ 
	public void setInactivatedDateTime(DTM objinactivatedDateTime)
	{
		setDataType(2295,objinactivatedDateTime);
	}
	
	/**
	 * Set the Modified DateTime
	 * @param strDateTimePlannedEvent This field contains the date/time that the event is planned. 
	 */
	public void setModifiedDateTime (String strDateTimePlannedEvent) 
	{
		DTM modifiedDateTime  = (DTM)getDataElement(2299);
		modifiedDateTime.setValue(strDateTimePlannedEvent);
		setModifiedDateTime(modifiedDateTime);


	} 

	/** Set the Modified DateTime.
	 * @param strTime Specifies a point in time using a 24-hour clock notation. 
	 * @param objstatusedDateTime object of Statused Date Time.
	 */ 
	public void setModifiedDateTime(DTM objmodifiedDateTime)
	{
		setDataType(2299,objmodifiedDateTime);
	}
	
	/**
	 * Set the Inactivated Date Time.
	 * @param strDateTimePlannedEvent This field contains the date/time that the event is planned. 
	 */
	public void setInitiallyRecordedDateTime (String strDateTimePlannedEvent) 
	{
		DTM initiallyRecordedDateTime  = (DTM)getDataElement(2297);
		initiallyRecordedDateTime.setValue(strDateTimePlannedEvent);
		setInitiallyRecordedDateTime(initiallyRecordedDateTime);


	} 

	/** Set the Initially Recorded DateTime.
	 * @param strTime Specifies a point in time using a 24-hour clock notation. 
	 * @param objstatusedDateTime object of Statused Date Time.
	 */ 
	public void setInitiallyRecordedDateTime(DTM objinitiallyRecordedDateTime)
	{
		setDataType(2297,objinitiallyRecordedDateTime);
	}
	
	/**
	 * Set the Statused Organization.
	 * This field contains the name of the organization providing the update to the allergy.
	 * @param strOrganizationName Specifies name of the specified organization.
	 * @param strOrganizationNameTypeCode Specifies a code that represents the type of name i.e., legal name, display name.
	 * 										Suggested Values A,L,D,SL.[Refer to table No.0204]  
	 * @param objAssigningAuthority Specifies The assigning authority is a unique identifier of the system 
	 * 									(or organization or agency or department) that creates the data. 
	 * @param strIdentifierTypeCode Specifies a code corresponding to the type of identifier. 
	 * @param objAssigningFacility Specifies The place or location identifier where the identifier was first assigned to the person. 
	 * @param strNameRepresentationCode Specifies representations of the same name/address Suggested values are I,A,P [Refer table 0465] 
	 * @param strOrganizationIdentifier This component contains the sequence of characters (the code) that uniquely 
	 * 									  identifies the item being referenced by XON.1 Organization Name. 
	 * 									  This component replaces XON.3 ID Number as of v 2.5.
	 */ 
	public void setStatusedOrganization (String strOrganizationName, CWE objOrganizationNameTypeCode,
			 HD objAssigningAuthority,
			String strIdentifierTypeCode, HD objAssigningFacility, String strNameRepresentationCode,
			String strOrganizationIdentifier)
	{
		XON statusedOrganization  = (XON)getDataElement(1564);
		statusedOrganization.setOrganizationName(strOrganizationName);
		statusedOrganization.setOrganizationNameTypeCode(objOrganizationNameTypeCode);
		//statusedOrganization.setOrganizationNameTypeCode(strOrganizationNameTypeCode);
//		statusedOrganization.setIdNumber(strIdNumber);
//		statusedOrganization.setCheckDigit(strCheckDigit);
//		statusedOrganization.setCheckDigitScheme(strCheckDigitScheme);
		statusedOrganization.setAssigningAuthority(objAssigningAuthority);
		statusedOrganization.setIdentifierTypeCode(strIdentifierTypeCode);
		statusedOrganization.setAssigningFacility(objAssigningFacility);
		statusedOrganization.setNameRepresentationCode(strNameRepresentationCode);
		statusedOrganization.setOrganizationIdentifier(strOrganizationIdentifier); 
		setStatusedOrganization(statusedOrganization);


	} 

	/**
	 * Ses the Statused Organization.
	 * @param objstatusedOrganization object of Statused Organization. 
	 */ 
	public void setStatusedOrganization(XON objstatusedOrganization)
	{
		setDataType(1564,objstatusedOrganization);
	}
	
	/**
	 * Set the Initially Recorded Organization
	 * @param strOrganizationName Specifies name of the specified organization.
	 * @param strOrganizationNameTypeCode Specifies a code that represents the type of name i.e., legal name, display name.
	 * 										Suggested Values A,L,D,SL.[Refer to table No.0204]  
	 * @param objAssigningAuthority Specifies The assigning authority is a unique identifier of the system 
	 * 									(or organization or agency or department) that creates the data. 
	 * @param strIdentifierTypeCode Specifies a code corresponding to the type of identifier. 
	 * @param objAssigningFacility Specifies The place or location identifier where the identifier was first assigned to the person. 
	 * @param strNameRepresentationCode Specifies representations of the same name/address Suggested values are I,A,P [Refer table 0465] 
	 * @param strOrganizationIdentifier This component contains the sequence of characters (the code) that uniquely 
	 * 									  identifies the item being referenced by XON.1 Organization Name. 
	 * 									  This component replaces XON.3 ID Number as of v 2.5.
	 */ 
	public void setInitiallyRecordedOrganization (String strOrganizationName, CWE objOrganizationNameTypeCode,
			 HD objAssigningAuthority,
			String strIdentifierTypeCode, HD objAssigningFacility, String strNameRepresentationCode,
			String strOrganizationIdentifier)
	{
		XON initiallyRecordedOrganization   = (XON)getDataElement(3293);
		initiallyRecordedOrganization.setOrganizationName(strOrganizationName);
		initiallyRecordedOrganization.setOrganizationNameTypeCode(objOrganizationNameTypeCode);
		initiallyRecordedOrganization.setAssigningAuthority(objAssigningAuthority);
		initiallyRecordedOrganization.setIdentifierTypeCode(strIdentifierTypeCode);
		initiallyRecordedOrganization.setAssigningFacility(objAssigningFacility);
		initiallyRecordedOrganization.setNameRepresentationCode(strNameRepresentationCode);
		initiallyRecordedOrganization.setOrganizationIdentifier(strOrganizationIdentifier); 
		setInitiallyRecordedOrganization(initiallyRecordedOrganization);


	} 

	/**
	 * Sets the Initially Recorded Organization.
	 * @param objinitiallyRecordedOrganization object of Initially Recorded Organization 
	 */ 
	public void setInitiallyRecordedOrganization(XON objinitiallyRecordedOrganization)
	{
		setDataType(3293,objinitiallyRecordedOrganization);
	}

	/**
	 * Set the Modified By Organization 
	 * @param strOrganizationName Specifies name of the specified organization.
	 * @param strOrganizationNameTypeCode Specifies a code that represents the type of name i.e., legal name, display name.
	 * 										Suggested Values A,L,D,SL.[Refer to table No.0204]  
	 * @param objAssigningAuthority Specifies The assigning authority is a unique identifier of the system 
	 * 									(or organization or agency or department) that creates the data. 
	 * @param strIdentifierTypeCode Specifies a code corresponding to the type of identifier. 
	 * @param objAssigningFacility Specifies The place or location identifier where the identifier was first assigned to the person. 
	 * @param strNameRepresentationCode Specifies representations of the same name/address Suggested values are I,A,P [Refer table 0465] 
	 * @param strOrganizationIdentifier This component contains the sequence of characters (the code) that uniquely 
	 * 									  identifies the item being referenced by XON.1 Organization Name. 
	 * 									  This component replaces XON.3 ID Number as of v 2.5.
	 */ 
	public void setModifiedByOrganization (String strOrganizationName, CWE objOrganizationNameTypeCode,
			 HD objAssigningAuthority,
			String strIdentifierTypeCode, HD objAssigningFacility, String strNameRepresentationCode,
			String strOrganizationIdentifier)
	{
		XON modifiedByOrganization   = (XON)getDataElement(3294);
		modifiedByOrganization .setOrganizationName(strOrganizationName);
		modifiedByOrganization .setOrganizationNameTypeCode(objOrganizationNameTypeCode);
		modifiedByOrganization .setAssigningAuthority(objAssigningAuthority);
		modifiedByOrganization .setIdentifierTypeCode(strIdentifierTypeCode);
		modifiedByOrganization .setAssigningFacility(objAssigningFacility);
		modifiedByOrganization .setNameRepresentationCode(strNameRepresentationCode);
		modifiedByOrganization .setOrganizationIdentifier(strOrganizationIdentifier); 
		setModifiedByOrganization (modifiedByOrganization );


	} 

	/**
	 * Sets the Modified By Organization.
	 * @param objmodifiedByOrganization object of Modified By Organization
	 */ 
	public void setModifiedByOrganization(XON objmodifiedByOrganization)
	{
		setDataType(3294,objmodifiedByOrganization);
	}
	
	/**
	 * Set the Inactivated By Organization 
	 * @param strOrganizationName Specifies name of the specified organization.
	 * @param strOrganizationNameTypeCode Specifies a code that represents the type of name i.e., legal name, display name.
	 * 										Suggested Values A,L,D,SL.[Refer to table No.0204]  
	 * @param objAssigningAuthority Specifies The assigning authority is a unique identifier of the system 
	 * 									(or organization or agency or department) that creates the data. 
	 * @param strIdentifierTypeCode Specifies a code corresponding to the type of identifier. 
	 * @param objAssigningFacility Specifies The place or location identifier where the identifier was first assigned to the person. 
	 * @param strNameRepresentationCode Specifies representations of the same name/address Suggested values are I,A,P [Refer table 0465] 
	 * @param strOrganizationIdentifier This component contains the sequence of characters (the code) that uniquely 
	 * 									  identifies the item being referenced by XON.1 Organization Name. 
	 * 									  This component replaces XON.3 ID Number as of v 2.5.
	 */ 
	public void setInactivatedByOrganization (String strOrganizationName, CWE objOrganizationNameTypeCode,
			 HD objAssigningAuthority,
			String strIdentifierTypeCode, HD objAssigningFacility, String strNameRepresentationCode,
			String strOrganizationIdentifier)
	{
		XON inactivatedByOrganization   = (XON)getDataElement(3295);
		inactivatedByOrganization  .setOrganizationName(strOrganizationName);
		inactivatedByOrganization  .setOrganizationNameTypeCode(objOrganizationNameTypeCode);
		inactivatedByOrganization .setAssigningAuthority(objAssigningAuthority);
		inactivatedByOrganization .setIdentifierTypeCode(strIdentifierTypeCode);
		inactivatedByOrganization  .setAssigningFacility(objAssigningFacility);
		inactivatedByOrganization  .setNameRepresentationCode(strNameRepresentationCode);
		inactivatedByOrganization .setOrganizationIdentifier(strOrganizationIdentifier); 
		setInactivatedByOrganization  (inactivatedByOrganization  );


	} 

	/**
	 * Sets the Inactivated By Organization.
	 * @param objinactivatedByOrganization object of Inactivated By Organization
	 */ 
	public void setInactivatedByOrganization(XON objinactivatedByOrganization)
	{
		setDataType(3295,objinactivatedByOrganization);
	}
	
	/**
	 * Set the Statused Person.
	 * This field identify the provider who assigned the clinical status to the allergy. 
	 * @param strIDNumber Refers to the coded ID according to a user-defined table
	 * @param objFamilyName Specifies the surname of a person.
	 * @param strGivenName Specifies First name.
	 * @param strSecondAndFurtherGivenNamesOrInitialsThereof Specifies multiple middle names that may be included by 
	 * 														   separating them with spaces.
	 * @param strSuffix Used to specify a name suffix (e.g., Jr. or III).
	 * @param strPrefix Used to specify a name prefix (e.g., Dr.).
	 * @param strSourceTable Used as the HL7 identifier for the user-defined table of values for this component. [Refer User-defined Table 0297 - CN ID.]
	 * @param objAssigningAuthority Specifies a unique identifier of the system (or organization or agency of department)
	 * 								  that creates the data. [Refer User-defined Table 0363 - Assigning authority]
	 * @param strNameTypeCode Specifies a code that represents the type of name. 
	 * @param strIdentifierCheckDigit Specifies part of the identifying number used in the sending application. 
	 * @param strCheckDigitScheme Specifies the code identifying the check digit scheme employed.[Refer HL7 Table 0061 - Check digit scheme].
	 * @param strIdentifierTypeCode Specifies A code corresponding to the type of identifier.[Refer HL7 Table 0203 - Identifier type].
	 * @param objAssigningFacility Specifies the place or location identifier where the identifier was first assigned to the person
	 * @param strNameRepresentationCode Provides an indication of the representation provided by the data item.  
	 * @param objNameContext Designates the context in which a name is used. [Refer User-defined Table 0448 ]
	 * @param strNameAssemblyOrder Specifies a code that represents the preferred display order of the components of this person name. Suggested values are G,F[Refer table 0444.]
	 * @param strEffectiveDate Specifies the first date, if known, on which the address is valid and active.
	 * @param strExpirationDate Specifies the last date, if known, on which the address is valid and active.
	 * @param strProfessionalSuffix Used to specify an abbreviation, or a string of abbreviations, denoting qualifications that support the person's profession, (e.g., licenses).
	 * @param objAssigningJurisdiction Specifies the geo-political body that assigned the identifier.
	 * @param objAssigningAgencyOrDepratment Specifies the agency or department that assigned the identifier
	 * @param strSecurityCheck Specifies the version code that may be assigned to the person identifier
	 * @param strSecurityCheckScheme Specifies the check digit scheme.
	 */ 
	public void setStatusedPerson (String strIDNumber,FN objFamilyName,String strGivenName,String strSecondAndFurtherGivenNamesOrInitialsThereof,
			String 	strSuffix,String strPrefix,CWE objSourceTable,HD objAssigningAuthority,
			String strNameTypeCode,String strIdentifierCheckDigit,String strCheckDigitScheme,String strIdentifierTypeCode,
			HD objAssigningFacility,String strNameRepresentationCode,CWE objNameContext,
			String strNameAssemblyOrder, String strEffectiveDate,String strExpirationDate,String strProfessionalSuffix,
			CWE objAssigningJurisdiction,CWE objAssigningAgencyOrDepratment, String strSecurityCheck, String strSecurityCheckScheme)
	{
		XCN statusedPerson  = (XCN)getDataElement(1563);
		statusedPerson.setIdNumber(strIDNumber);
		statusedPerson.setFamilyName(objFamilyName);
		statusedPerson.setGivenName(strGivenName);
		statusedPerson.setSecondNameOrInitials(strSecondAndFurtherGivenNamesOrInitialsThereof);
		statusedPerson.setSuffix(strSuffix);
		statusedPerson.setPrefix(strPrefix);
//		statusedPerson.setDegree(strDegree);
		statusedPerson.setSourceTable(objSourceTable);
		statusedPerson.setAssigningAuthority(objAssigningAuthority);
		statusedPerson.setNameTypeCode(strNameTypeCode);
		statusedPerson.setIdentifierCheckDigit(strIdentifierCheckDigit);
		statusedPerson.setCheckDigitScheme(strCheckDigitScheme);
		statusedPerson.setIdentifierTypeCode(strIdentifierTypeCode);
		statusedPerson.setAssigningFacility(objAssigningFacility);
		statusedPerson.setNameRepresentationCode(strNameRepresentationCode);
		statusedPerson.setNameContext(objNameContext);
//		statusedPerson.setNameValidityRange(objNameValidityRange);
		statusedPerson.setNameAssemblyOrder(strNameAssemblyOrder);
		statusedPerson.setEffectiveDate(strEffectiveDate);
		statusedPerson.setExpirationDate(strExpirationDate);
		statusedPerson.setProfessionalSuffix(strProfessionalSuffix);
		statusedPerson.setAssigningJurisdiction(objAssigningJurisdiction);
		statusedPerson.setAssigningAgencyOrDepartment(objAssigningAgencyOrDepratment); 
		statusedPerson.setSecurityCheck(strSecurityCheck);
		statusedPerson.setSecurityCheckScheme(strSecurityCheckScheme);
		setStatusedPerson(statusedPerson);


	} 

	/**
	 * Sets the Statused Person.
	 * @param objstatusedPerson object of Statused Person.
	 */ 
	public void setStatusedPerson(XCN objstatusedPerson)
	{
		setDataType(1563,objstatusedPerson);
	}
	
	/**
	 * Set the Initially Recorded By Person
	 * @param strIDNumber Refers to the coded ID according to a user-defined table
	 * @param objFamilyName Specifies the surname of a person.
	 * @param strGivenName Specifies First name.
	 * @param strSecondAndFurtherGivenNamesOrInitialsThereof Specifies multiple middle names that may be included by 
	 * 														   separating them with spaces.
	 * @param strSuffix Used to specify a name suffix (e.g., Jr. or III).
	 * @param strPrefix Used to specify a name prefix (e.g., Dr.).
	 * @param strSourceTable Used as the HL7 identifier for the user-defined table of values for this component. [Refer User-defined Table 0297 - CN ID.]
	 * @param objAssigningAuthority Specifies a unique identifier of the system (or organization or agency of department)
	 * 								  that creates the data. [Refer User-defined Table 0363 - Assigning authority]
	 * @param strNameTypeCode Specifies a code that represents the type of name. 
	 * @param strIdentifierCheckDigit Specifies part of the identifying number used in the sending application. 
	 * @param strCheckDigitScheme Specifies the code identifying the check digit scheme employed.[Refer HL7 Table 0061 - Check digit scheme].
	 * @param strIdentifierTypeCode Specifies A code corresponding to the type of identifier.[Refer HL7 Table 0203 - Identifier type].
	 * @param objAssigningFacility Specifies the place or location identifier where the identifier was first assigned to the person
	 * @param strNameRepresentationCode Provides an indication of the representation provided by the data item.  
	 * @param objNameContext Designates the context in which a name is used. [Refer User-defined Table 0448 ]
	 * @param strNameAssemblyOrder Specifies a code that represents the preferred display order of the components of this person name. Suggested values are G,F[Refer table 0444.]
	 * @param strEffectiveDate Specifies the first date, if known, on which the address is valid and active.
	 * @param strExpirationDate Specifies the last date, if known, on which the address is valid and active.
	 * @param strProfessionalSuffix Used to specify an abbreviation, or a string of abbreviations, denoting qualifications that support the person's profession, (e.g., licenses).
	 * @param objAssigningJurisdiction Specifies the geo-political body that assigned the identifier.
	 * @param objAssigningAgencyOrDepratment Specifies the agency or department that assigned the identifier
	 * @param strSecurityCheck Specifies the version code that may be assigned to the person identifier
	 * @param strSecurityCheckScheme Specifies the check digit scheme.
	 */ 
	public void setInitiallyRecordedByPerson (String strIDNumber,FN objFamilyName,String strGivenName,String strSecondAndFurtherGivenNamesOrInitialsThereof,
			String 	strSuffix,String strPrefix,CWE objSourceTable,HD objAssigningAuthority,
			String strNameTypeCode,String strIdentifierCheckDigit,String strCheckDigitScheme,String strIdentifierTypeCode,
			HD objAssigningFacility,String strNameRepresentationCode,CWE objNameContext,
			String strNameAssemblyOrder, String strEffectiveDate,String strExpirationDate,String strProfessionalSuffix,
			CWE objAssigningJurisdiction,CWE objAssigningAgencyOrDepratment, String strSecurityCheck, String strSecurityCheckScheme)
	{
		XCN initiallyRecordedByPerson  = (XCN)getDataElement(2296);
		initiallyRecordedByPerson.setIdNumber(strIDNumber);
		initiallyRecordedByPerson.setFamilyName(objFamilyName);
		initiallyRecordedByPerson.setGivenName(strGivenName);
		initiallyRecordedByPerson.setSecondNameOrInitials(strSecondAndFurtherGivenNamesOrInitialsThereof);
		initiallyRecordedByPerson.setSuffix(strSuffix);
		initiallyRecordedByPerson.setPrefix(strPrefix);
//		statusedPerson.setDegree(strDegree);
		initiallyRecordedByPerson.setSourceTable(objSourceTable);
		initiallyRecordedByPerson.setAssigningAuthority(objAssigningAuthority);
		initiallyRecordedByPerson.setNameTypeCode(strNameTypeCode);
		initiallyRecordedByPerson.setIdentifierCheckDigit(strIdentifierCheckDigit);
		initiallyRecordedByPerson.setCheckDigitScheme(strCheckDigitScheme);
		initiallyRecordedByPerson.setIdentifierTypeCode(strIdentifierTypeCode);
		initiallyRecordedByPerson.setAssigningFacility(objAssigningFacility);
		initiallyRecordedByPerson.setNameRepresentationCode(strNameRepresentationCode);
		initiallyRecordedByPerson.setNameContext(objNameContext);
//		statusedPerson.setNameValidityRange(objNameValidityRange);
		initiallyRecordedByPerson.setNameAssemblyOrder(strNameAssemblyOrder);
		initiallyRecordedByPerson.setEffectiveDate(strEffectiveDate);
		initiallyRecordedByPerson.setExpirationDate(strExpirationDate);
		initiallyRecordedByPerson.setProfessionalSuffix(strProfessionalSuffix);
		initiallyRecordedByPerson.setAssigningJurisdiction(objAssigningJurisdiction);
		initiallyRecordedByPerson.setAssigningAgencyOrDepartment(objAssigningAgencyOrDepratment); 
		initiallyRecordedByPerson.setSecurityCheck(strSecurityCheck);
		initiallyRecordedByPerson.setSecurityCheckScheme(strSecurityCheckScheme);
		setInitiallyRecordedByPerson(initiallyRecordedByPerson);


	} 

	/**
	 * Sets the Initially Recorded By Person
	 * @param objinitiallyRecordedByPerson object of Initially Recorded By Person
	 */ 
	public void setInitiallyRecordedByPerson(XCN objinitiallyRecordedByPerson)
	{
		setDataType(2296,objinitiallyRecordedByPerson);
	}
	
	/**
	 * Set the Modified By Person
	 * @param strIDNumber Refers to the coded ID according to a user-defined table
	 * @param objFamilyName Specifies the surname of a person.
	 * @param strGivenName Specifies First name.
	 * @param strSecondAndFurtherGivenNamesOrInitialsThereof Specifies multiple middle names that may be included by 
	 * 														   separating them with spaces.
	 * @param strSuffix Used to specify a name suffix (e.g., Jr. or III).
	 * @param strPrefix Used to specify a name prefix (e.g., Dr.).
	 * @param strSourceTable Used as the HL7 identifier for the user-defined table of values for this component. [Refer User-defined Table 0297 - CN ID.]
	 * @param objAssigningAuthority Specifies a unique identifier of the system (or organization or agency of department)
	 * 								  that creates the data. [Refer User-defined Table 0363 - Assigning authority]
	 * @param strNameTypeCode Specifies a code that represents the type of name. 
	 * @param strIdentifierCheckDigit Specifies part of the identifying number used in the sending application. 
	 * @param strCheckDigitScheme Specifies the code identifying the check digit scheme employed.[Refer HL7 Table 0061 - Check digit scheme].
	 * @param strIdentifierTypeCode Specifies A code corresponding to the type of identifier.[Refer HL7 Table 0203 - Identifier type].
	 * @param objAssigningFacility Specifies the place or location identifier where the identifier was first assigned to the person
	 * @param strNameRepresentationCode Provides an indication of the representation provided by the data item.  
	 * @param objNameContext Designates the context in which a name is used. [Refer User-defined Table 0448 ]
	 * @param strNameAssemblyOrder Specifies a code that represents the preferred display order of the components of this person name. Suggested values are G,F[Refer table 0444.]
	 * @param strEffectiveDate Specifies the first date, if known, on which the address is valid and active.
	 * @param strExpirationDate Specifies the last date, if known, on which the address is valid and active.
	 * @param strProfessionalSuffix Used to specify an abbreviation, or a string of abbreviations, denoting qualifications that support the person's profession, (e.g., licenses).
	 * @param objAssigningJurisdiction Specifies the geo-political body that assigned the identifier.
	 * @param objAssigningAgencyOrDepratment Specifies the agency or department that assigned the identifier
	 * @param strSecurityCheck Specifies the version code that may be assigned to the person identifier
	 * @param strSecurityCheckScheme Specifies the check digit scheme.
	 */ 
	public void setModifiedByPerson (String strIDNumber,FN objFamilyName,String strGivenName,String strSecondAndFurtherGivenNamesOrInitialsThereof,
			String 	strSuffix,String strPrefix,CWE objSourceTable,HD objAssigningAuthority,
			String strNameTypeCode,String strIdentifierCheckDigit,String strCheckDigitScheme,String strIdentifierTypeCode,
			HD objAssigningFacility,String strNameRepresentationCode,CWE objNameContext,
			String strNameAssemblyOrder, String strEffectiveDate,String strExpirationDate,String strProfessionalSuffix,
			CWE objAssigningJurisdiction,CWE objAssigningAgencyOrDepratment, String strSecurityCheck, String strSecurityCheckScheme)
	{
		XCN modifiedByPerson  = (XCN)getDataElement(2298);
		modifiedByPerson.setIdNumber(strIDNumber);
		modifiedByPerson.setFamilyName(objFamilyName);
		modifiedByPerson.setGivenName(strGivenName);
		modifiedByPerson.setSecondNameOrInitials(strSecondAndFurtherGivenNamesOrInitialsThereof);
		modifiedByPerson.setSuffix(strSuffix);
		modifiedByPerson.setPrefix(strPrefix);
//		statusedPerson.setDegree(strDegree);
		modifiedByPerson.setSourceTable(objSourceTable);
		modifiedByPerson.setAssigningAuthority(objAssigningAuthority);
		modifiedByPerson.setNameTypeCode(strNameTypeCode);
		modifiedByPerson.setIdentifierCheckDigit(strIdentifierCheckDigit);
		modifiedByPerson.setCheckDigitScheme(strCheckDigitScheme);
		modifiedByPerson.setIdentifierTypeCode(strIdentifierTypeCode);
		modifiedByPerson.setAssigningFacility(objAssigningFacility);
		modifiedByPerson.setNameRepresentationCode(strNameRepresentationCode);
		modifiedByPerson.setNameContext(objNameContext);
//		statusedPerson.setNameValidityRange(objNameValidityRange);
		modifiedByPerson.setNameAssemblyOrder(strNameAssemblyOrder);
		modifiedByPerson.setEffectiveDate(strEffectiveDate);
		modifiedByPerson.setExpirationDate(strExpirationDate);
		modifiedByPerson.setProfessionalSuffix(strProfessionalSuffix);
		modifiedByPerson.setAssigningJurisdiction(objAssigningJurisdiction);
		modifiedByPerson.setAssigningAgencyOrDepartment(objAssigningAgencyOrDepratment); 
		modifiedByPerson.setSecurityCheck(strSecurityCheck);
		modifiedByPerson.setSecurityCheckScheme(strSecurityCheckScheme);
		setModifiedByPerson(modifiedByPerson);


	} 

	/**
	 * Sets the ModifiedByPerson
	 * @param objmodifiedByPerson object of Modified By Person
	 */ 
	public void setModifiedByPerson(XCN objmodifiedByPerson)
	{
		setDataType(2298,objmodifiedByPerson);
	}
	
	/**
	 * Set the Inactivated By Person. 
	 * @param strIDNumber Refers to the coded ID according to a user-defined table
	 * @param objFamilyName Specifies the surname of a person.
	 * @param strGivenName Specifies First name.
	 * @param strSecondAndFurtherGivenNamesOrInitialsThereof Specifies multiple middle names that may be included by 
	 * 														   separating them with spaces.
	 * @param strSuffix Used to specify a name suffix (e.g., Jr. or III).
	 * @param strPrefix Used to specify a name prefix (e.g., Dr.).
	 * @param strSourceTable Used as the HL7 identifier for the user-defined table of values for this component. [Refer User-defined Table 0297 - CN ID.]
	 * @param objAssigningAuthority Specifies a unique identifier of the system (or organization or agency of department)
	 * 								  that creates the data. [Refer User-defined Table 0363 - Assigning authority]
	 * @param strNameTypeCode Specifies a code that represents the type of name. 
	 * @param strIdentifierCheckDigit Specifies part of the identifying number used in the sending application. 
	 * @param strCheckDigitScheme Specifies the code identifying the check digit scheme employed.[Refer HL7 Table 0061 - Check digit scheme].
	 * @param strIdentifierTypeCode Specifies A code corresponding to the type of identifier.[Refer HL7 Table 0203 - Identifier type].
	 * @param objAssigningFacility Specifies the place or location identifier where the identifier was first assigned to the person
	 * @param strNameRepresentationCode Provides an indication of the representation provided by the data item.  
	 * @param objNameContext Designates the context in which a name is used. [Refer User-defined Table 0448 ]
	 * @param strNameAssemblyOrder Specifies a code that represents the preferred display order of the components of this person name. Suggested values are G,F[Refer table 0444.]
	 * @param strEffectiveDate Specifies the first date, if known, on which the address is valid and active.
	 * @param strExpirationDate Specifies the last date, if known, on which the address is valid and active.
	 * @param strProfessionalSuffix Used to specify an abbreviation, or a string of abbreviations, denoting qualifications that support the person's profession, (e.g., licenses).
	 * @param objAssigningJurisdiction Specifies the geo-political body that assigned the identifier.
	 * @param objAssigningAgencyOrDepratment Specifies the agency or department that assigned the identifier
	 * @param strSecurityCheck Specifies the version code that may be assigned to the person identifier
	 * @param strSecurityCheckScheme Specifies the check digit scheme.
	 */ 
	public void setInactivatedByPerson (String strIDNumber,FN objFamilyName,String strGivenName,String strSecondAndFurtherGivenNamesOrInitialsThereof,
			String 	strSuffix,String strPrefix,CWE objSourceTable,HD objAssigningAuthority,
			String strNameTypeCode,String strIdentifierCheckDigit,String strCheckDigitScheme,String strIdentifierTypeCode,
			HD objAssigningFacility,String strNameRepresentationCode,CWE objNameContext,
			String strNameAssemblyOrder, String strEffectiveDate,String strExpirationDate,String strProfessionalSuffix,
			CWE objAssigningJurisdiction,CWE objAssigningAgencyOrDepratment, String strSecurityCheck, String strSecurityCheckScheme)
	{
		XCN InactivatedByPerson  = (XCN)getDataElement(2294);
		InactivatedByPerson .setIdNumber(strIDNumber);
		InactivatedByPerson .setFamilyName(objFamilyName);
		InactivatedByPerson .setGivenName(strGivenName);
		InactivatedByPerson .setSecondNameOrInitials(strSecondAndFurtherGivenNamesOrInitialsThereof);
		InactivatedByPerson .setSuffix(strSuffix);
		InactivatedByPerson .setPrefix(strPrefix);
		InactivatedByPerson .setSourceTable(objSourceTable);
		InactivatedByPerson .setAssigningAuthority(objAssigningAuthority);
		InactivatedByPerson .setNameTypeCode(strNameTypeCode);
		InactivatedByPerson .setIdentifierCheckDigit(strIdentifierCheckDigit);
		InactivatedByPerson .setCheckDigitScheme(strCheckDigitScheme);
		InactivatedByPerson .setIdentifierTypeCode(strIdentifierTypeCode);
		InactivatedByPerson .setAssigningFacility(objAssigningFacility);
		InactivatedByPerson .setNameRepresentationCode(strNameRepresentationCode);
		InactivatedByPerson .setNameContext(objNameContext);
		InactivatedByPerson .setNameAssemblyOrder(strNameAssemblyOrder);
		InactivatedByPerson .setEffectiveDate(strEffectiveDate);
		InactivatedByPerson .setExpirationDate(strExpirationDate);
		InactivatedByPerson .setProfessionalSuffix(strProfessionalSuffix);
		InactivatedByPerson .setAssigningJurisdiction(objAssigningJurisdiction);
		InactivatedByPerson .setAssigningAgencyOrDepartment(objAssigningAgencyOrDepratment); 
		InactivatedByPerson .setSecurityCheck(strSecurityCheck);
		InactivatedByPerson .setSecurityCheckScheme(strSecurityCheckScheme);
		setInactivatedByPerson (InactivatedByPerson );


	} 

	/**
	 * Sets the Inactivated By Person.
	 * @param objinactivatedByPerson object of Statused Person.
	 */ 
	public void setInactivatedByPerson(XCN objinactivatedByPerson)
	{
		setDataType(2294,objinactivatedByPerson);
	}

	/**
	 * Validates HL7 Message objects .
	 * Validate method checks for validation each and every segments in side the Message object against specified message Structure. 
	 * Validation chcecks include optionality of segment or group.
	 * It also verifies the number of times segment or group is repeated in message.
	 * e.g 
	 * {PSH} while parsing PSH segment validate method will check for its mandatory presence.
	 * [PSH] in this case validate will throw exception if one tries to enter more than one PSH segment.
	 * @return boolean - true or false.
	 * @throws InvalidSegmentException If Segment Validation fails
	 */
	public boolean validate() throws InvalidSegmentException
	{
		try
		{
			/*
			 * For this segment there is the conditional field "allergyUniqueIdentifier",which has following description,
			 *If a system maintains allergen codes as a unique identifier for a particular allergy, 
			 *then this field should not be used
			 *This field is conditionally required.  
			 *The surrogate field to use is IAM-3 - Allergen Code/Mnemonic/Description, 
			 *if that field can uniquely identify the allergy on the receiving system.
			 *Not yet added the code for the condition,has to be taken care.
			 *
			 *Note: As Discussed By MD, the conditional field "allergyUniqueIdentifier" is considered as Optional,
			 *thus no need to have any condition here. 
			 */
			super.validate();
			return true;
		}
		catch(FieldMissingException ex)
		{
			throw new InvalidSegmentException(enumSegments.getValue(),ex);
		}
	}
}