/*******************************************************************************
 *  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.hl7model.messages.financialmanagement;

import cdac.medinfo.sdk.hl7282.baselibs.messages.Message;
import cdac.medinfo.sdk.hl7282.baselibs.segments.ACC;
import cdac.medinfo.sdk.hl7282.baselibs.segments.DB1;
import cdac.medinfo.sdk.hl7282.baselibs.segments.DG1;
import cdac.medinfo.sdk.hl7282.baselibs.segments.DRG;
import cdac.medinfo.sdk.hl7282.baselibs.segments.EVN;
import cdac.medinfo.sdk.hl7282.baselibs.segments.GT1;
import cdac.medinfo.sdk.hl7282.baselibs.segments.PD1;
import cdac.medinfo.sdk.hl7282.baselibs.segments.PID;
import cdac.medinfo.sdk.hl7282.baselibs.segments.PRT;
import cdac.medinfo.sdk.hl7282.baselibs.segments.PV1;
import cdac.medinfo.sdk.hl7282.baselibs.segments.PV2;
import cdac.medinfo.sdk.hl7282.baselibs.segments.ROL;
import cdac.medinfo.sdk.hl7282.baselibs.segments.SFT;
import cdac.medinfo.sdk.hl7282.baselibs.segments.UAC;
import cdac.medinfo.sdk.hl7282.commoninterface.IGroup;
import cdac.medinfo.sdk.hl7282.commoninterface.ISegment;
import cdac.medinfo.sdk.hl7282.commoninterface.ISingleCollection;
import cdac.medinfo.sdk.hl7282.utils.EnumMessageCode;
import cdac.medinfo.sdk.hl7282.utils.EnumMessageStructure;
import cdac.medinfo.sdk.hl7282.utils.EnumSegments;
import cdac.medinfo.sdk.hl7282.utils.EnumTriggerEvent;
import cdac.medinfo.sdk.hl7282.utils.IMap;

/**
 * DFT_P03 - Post Detail Financial Transactions (Event P03).
 * This message is use to describe a financial transaction transmitted between systems, that is, 
 * to the billing system for ancillary charges.Use to billing system for patient deposits, etc.
 * <p>Represents a DFT_P03 message structure (see chapter 6.4.3). This structure contains the 
 * following elements: </p>
 * 0: MSH (Message Header Segment) <b>SINGLE_COMPULSARY</b><br>
 * 1: SFT (Software Segment ) <b>MULTIPLE_OPTIONAL</b><br>
 * 2: UAC (User Authentication Credential segment) <b>SINGLE_OPTIONAL</b><br> 
 * 3: EVN (Event Type Segment) <b>SINGLE_COMPULSARY</b><br>
 * 4: PID (Patient Identification Segment) <b>SINGLE_COMPULSARY</b><br>
 * 5: PD1 (Patient Additional Demographic Segment) <b>SINGLE_OPTIONAL</b><br>
 * 6: PRT (Participation Segment) <b>MULTIPLE_OPTIONAL</b><br>
 * 7: ROL (Role) <b>MULTIPLE_OPTIONAL</b><br>
 * 8: PV1 (Patient Visit Segment) <b>SINGLE_OPTIONAL</b><br>
 * 9: PV2 (Patient Visit - Additional Information Segment) <b>SINGLE_OPTIONAL</b><br>
 * 10: PRT (Participation Segment) <b>MULTIPLE_OPTIONAL</b><br>
 * 11: ROL (Role) <b>MULTIPLE_OPTIONAL</b><br>
 * 12: DB1 (Disability) <b>MULTIPLE_OPTIONAL</b><br>
 * 13: COMMON_ORDER (a Group of segments in DFT_P03 message) <b>MULTIPLE_OPTIONAL</b><br>
 * 14: FINANCIAL (a Group of segments in DFT_P03 message) <b>MULTIPLE_COMPULSARY</b><br>
 * 15: DG1 (Diagnosis Segment) <b>MULTIPLE_OPTIONAL</b><br>
 * 16: DRG (Diagnosis Related Group Segment) <b>SINGLE_OPTIONAL</b><br>
 * 17: GT1 (Guarantor Segment) <b>MULTIPLE_OPTIONAL</b><br>
 * 18: INSURANCE (a Group of segments in DFT_P03 message) <b>MULTIPLE_OPTIONAL</b><br>
 * 19: ACC (Accident Segment) <b>SINGLE_OPTIONAL</b><br>
 * This class provides mechanism to validate message against HL7 v 2.8.2 standard.
 * The class provides accessors & mutators for the elements mentioned above.
 * These elements can be easily populated & populated values can be easily retrieved.
 * The class has validate method which validates Message against HL7 v 2.8.2 standard.
 *
 * <p>Following is the step to create message<br>
 * Before that, respective Message Source and Message Recipient to be set on Message Factory.</p>
 * <p>DFT_P03 objP03 = (DFT_P03)MessageFactory.createInstance().createSendSupportedMessage("DFT", "P03");</p>
 */
public final class DFT_P03 extends Message 
{

	/**
	 * Constructs the DFT_P03 message.
	 */
	DFT_P03(IMap objMessageMap)
	{
		super(objMessageMap, EnumMessageCode.DFT.getValue(), EnumTriggerEvent.P03.getValue(), EnumMessageStructure.DFT_P03.getValue());
	}

	/**
	 * Adds Software Segment(SFT) to this message.
	 * @param objSFT Specified Software Segment(SFT) to be added in this messageto this message.
	 */
	public void addSoftwareSegment(SFT objSFT)
	{
		addSegment(EnumSegments.HL7_SEG_SFT, objSFT);
	}

	/**
	 * Adds collection of Software Segment(SFT) to this message.
	 * @param objSFTSegmentCollection Collection of Software segments to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addSoftwareSegment(ISingleCollection<SFT> objSFTSegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objSFTSegmentCollection;
		addSegment(EnumSegments.HL7_SEG_SFT, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Software Segments(SFT) present in this message.
	 * @return ISingleCollection<SFT> - Collection of Software Segments(SFT) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<SFT> getSoftwareSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_SFT);
		return (ISingleCollection<SFT>)objSegmentCollection;
	}
	
	/**
	 * Retrieves User Authentication Credential(UAC) segment present in this message
	 * @return UAC - the User Authentication Credential Segment present in this message or null if unavailable. 
	 */
	public UAC getUserAuthenticationCredentialSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_UAC);
		if(objSingleCollection != null)
			return (UAC)objSingleCollection.elementAt(0);
		return null;
	}
	
	/**
	 * Sets value of User Authentication Credential(UAC) segment  for this message, overwrites if already present.
	 * @param objUAC Specified UAC Segment
	 */
	public void setUserAuthenticationCredentialSegment(UAC objUAC)
	{
		setSegment(EnumSegments.HL7_SEG_UAC,objUAC);
	}
	

	/**
	 * Retrieves Event Type(EVN) segment present in this message
	 * @return EVN - the EVN Segment present in this message or null if unavailable.
	 */
	public EVN getEventTypeSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_EVN);
		if(objSingleCollection != null)
			return (EVN)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of Event Type segment for this message,overwrites if already present.
	 * @param objEVN Specified EVN Segment 
	 */
	public void setEventTypeSegment(EVN objEVN)
	{
		setSegment(EnumSegments.HL7_SEG_EVN,objEVN);
	}

	/**
	 * Retrieves Patient Identification(PID) segment present in this message.
	 * @return PID - the Patient Identification Segment present in this message or null if unavailable.
	 */
	public PID getPatientIdentificationSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_PID);
		if(objSingleCollection != null)
			return (PID)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of PID segment for this message,overwrites if already present.
	 * @param objPID Specified PID Segment 
	 */
	public void setPatientIdentificationSegment(PID objPID)
	{
		setSegment(EnumSegments.HL7_SEG_PID,objPID);
	}

	/**
	 * Retrieves Additinal Demographics segment(PD1) present in this message.
	 * @return PD1 - the Additinal Demographics(PD1) Segment. present in this message or null if unavailable.
	 */
	public PD1 getAdditinalDemographicsSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_PD1);
		if(objSingleCollection != null)
			return (PD1)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of Additinal Demographics segment(PD1) for this message,overwrites if already present.
	 * @param objPD1 Specified Additinal Demographics(PD1) Segment. 
	 */
	public void setAdditinalDemographicsSegment(PD1 objPD1)
	{
		setSegment(EnumSegments.HL7_SEG_PD1,objPD1);
	}

	
	/**
	 * Retrieves Collection of Participation(PRT) Segment for patient identification present in this message.
	 * @return ISingleCollection<PRT> - collection of Participation(PRT) Segment present in message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<PRT> getPatientIdentificationParticipationSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_PRT_PATIENT_IDENTIFICATION);
		return (ISingleCollection<PRT>)objSegmentCollection;
	}
	
	/**
	 * Adds Participation(PRT) Segment for patient identification to this message.
	 * @param objPRT Specified Participation(PRT) Segment to be added in this message.
	 */
	public void addPatientIdentificationPaticipationSegment(PRT objPRT)
	{
		addSegment(EnumSegments.HL7_SEG_PRT_PATIENT_IDENTIFICATION, objPRT);
	}

	/**
	 * Adds collection of PArticipation(PRT) Segment for patient identification to this message.
	 * @param objPRTSegmentCollection Collection of Participation Segments to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addPatientIdentificationPaticipationSegments(ISingleCollection<PRT> objPRTSegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objPRTSegmentCollection;
		addSegment(EnumSegments.HL7_SEG_PRT_PATIENT_IDENTIFICATION, (ISingleCollection<ISegment>)objSegmentCollection);
	}


	/**
	 * Adds Role Segment(ROL) to this message.
	 * @param objROL Specified Role Segment to be added in message.
	 */
	public void addPatientIdentificationRoleSegment(ROL objROL)
	{
		addSegment(EnumSegments.HL7_SEG_ROL_PATIENT_IDENTIFICATION, objROL);
	}

	/**
	 * Adds collection of Role Segments(ROL) to this message.
	 * @param objROLSegmentCollection Collection of Role Segment(ROL) to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addPatientIdentificationRoleSegment(ISingleCollection<ROL> objROLSegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objROLSegmentCollection;
		addSegment(EnumSegments.HL7_SEG_ROL_PATIENT_IDENTIFICATION, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Role Segment(ROL) present in this message.
	 * @return ISingleCollection<ROL> - Collection of Role Segment(ROL) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<ROL> getPatientIdentificationRoleSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_ROL_PATIENT_IDENTIFICATION);
		return (ISingleCollection<ROL>)objSegmentCollection;
	}

	/**
	 * Retrieves Patient Visit(PV1) segment present in this message.
	 * @return PV1  - Patient Visit Segment present in this message or null if unavailable.
	 */
	public PV1 getPatientVisitSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_PV1);
		if(objSingleCollection != null)
			return (PV1)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of PV1  segment for this message,overwrites if already present.
	 * @param objPV1 Specified PV1  Segment
	 */
	public void setPatientVisitSegment(PV1  objPV1)
	{
		setSegment(EnumSegments.HL7_SEG_PV1, objPV1);
	}

	/**
	 * Retrieves Patient Visit Additiional Info(PV2) segment present in this message.
	 * @return PV2  - Patient Visit Segment present in this message or null if unavailable.
	 */
	public PV2 getPatientVisitAdditiionalInfoSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_PV2);
		if(objSingleCollection != null)
			return (PV2)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of Patient Visit Additiional Info(PV2)  segment for this message,overwrites if already present.
	 * @param objPV2 Specified PV2  Segment
	 */
	public void setPatientVisitAdditiionalInfoSegment(PV2  objPV2)
	{
		setSegment(EnumSegments.HL7_SEG_PV2, objPV2);
	}
	
	/**
	 * Retrieves Collection of Participation(PRT) Segment for patient visit present in this message.
	 * @return ISingleCollection<PRT> - collection of Participation(PRT) Segment present in message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<PRT> getPatientVisitPaticipationSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_PRT_PATIENT_VISIT);
		return (ISingleCollection<PRT>)objSegmentCollection;
	}
	
	/**
	 * Adds Participation(PRT) Segment for patient visit to this message.
	 * @param objPRT Specified Participation(PRT) Segment to be added in this message.
	 */
	public void addPatientVisitPaticipationSegment(PRT objPRT)
	{
		addSegment(EnumSegments.HL7_SEG_PRT_PATIENT_VISIT, objPRT);
	}

	/**
	 * Adds collection of PArticipation(PRT) Segment for patient visit to this message.
	 * @param objPRTSegmentCollection Collection of Participation Segments to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addPatientVisitPaticipationSegments(ISingleCollection<PRT> objPRTSegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objPRTSegmentCollection;
		addSegment(EnumSegments.HL7_SEG_PRT_PATIENT_VISIT, (ISingleCollection<ISegment>)objSegmentCollection);
	}
	

	/**
	 * Adds Role Segment(ROL) to this message.
	 * @param objROL Specified Role Segment to be added in message.
	 */
	public void addPatientVisitRoleSegment(ROL objROL)
	{
		addSegment(EnumSegments.HL7_SEG_ROL_PATIENT_VISIT, objROL);
	}

	/**
	 * Adds collection of Role Segments(ROL) to this message.
	 * @param objROLSegmentCollection Collection of Role Segment(ROL) to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addPatientVisitRoleSegment(ISingleCollection<ROL> objROLSegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objROLSegmentCollection;
		addSegment(EnumSegments.HL7_SEG_ROL_PATIENT_VISIT, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Role Segment(ROL) present in this message.
	 * @return ISingleCollection<ROL> - Collection of Role Segment(ROL) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<ROL> getPatientVisitRoleSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_ROL_PATIENT_VISIT);
		return (ISingleCollection<ROL>)objSegmentCollection;
	}

	/**
	 * Adds Disability Information(DB1) to this message.
	 * @param objDB1 Specified Disability Information Segment to be added in message.
	 */
	public void addDisabilityInformationSegment(DB1 objDB1)
	{
		addSegment(EnumSegments.HL7_SEG_DB1, objDB1);
	}

	/**
	 * Adds collection of Disability Information(DB1) to this message.
	 * @param objDB1SegmentCollection Collection of Disability Information(DB1) to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addDisabilityInformationSegment(ISingleCollection<DB1> objDB1SegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objDB1SegmentCollection;
		addSegment(EnumSegments.HL7_SEG_DB1, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Disability Information(DB1) present in this message.
	 * @return ISingleCollection<DB1> - Collection of Disability Information(DB1) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<DB1> getDisabilityInformationSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_DB1);
		return (ISingleCollection<DB1>)objSegmentCollection;
	}
	/**
	 * Retrieves Collection of Common Order GROUP present in this message.
	 * @return ISingleCollection<Group> - Collection of Common Order Group present in this Message.
	 */
	public ISingleCollection<IGroup> getCommonOrderGroups()
	{
		return getGroup(EnumSegments.HL7_GROUP_COMMON_ORDER);
	}

	/**
	 * Adds Collection of Common Order GROUP to this message.
	 * @param objSingleCollection Specified  Common Order GROUP Collection.
	 */
	public void addCommonOrderGroups(ISingleCollection<IGroup> objSingleCollection)
	{
		addGroup(EnumSegments.HL7_GROUP_COMMON_ORDER, objSingleCollection);
	}

	/**
	 * Adds Common Order GROUP to this message.
	 * @param objGroup Specified Common Order GROUP. 
	 */
	public void addCommonOrderGroup(IGroup objGroup)
	{
		addGroup(EnumSegments.HL7_GROUP_COMMON_ORDER, objGroup);
	}

	/**
	 * Adds Collection of Financial GROUP to this message.
	 * @param objSingleCollection Specified  Financial GROUP Collection.
	 */
	public void addFinancialGroups(ISingleCollection<IGroup> objSingleCollection)
	{
		addGroup(EnumSegments.HL7_GROUP_FINANCIAL, objSingleCollection);
	}

	/**
	 * Adds Financial GROUP to this message.
	 * @param objGroup Specified Financial GROUP. 
	 */
	public void addFinancialGroup(IGroup objGroup)
	{
		addGroup(EnumSegments.HL7_GROUP_FINANCIAL, objGroup);
	}

	/**
	 * Retrieves Collection of Insurance GROUP present in this message.
	 * @return ISingleCollection<Group> - Collection of Insurance Group present 
	 */
	public ISingleCollection<IGroup> getFinancialGroups()
	{
		return getGroup(EnumSegments.HL7_GROUP_FINANCIAL);
	}

	/**
	 * Adds Diagnosis Information(DG1) to this message.
	 * @param objDG1 Specified Diagnosis Information(DG1) Segment to this message.
	 */
	public void addDiagnosisInformationSegment(DG1 objDG1)
	{
		addSegment(EnumSegments.HL7_SEG_DG1, objDG1);
	}

	/**
	 * Adds collection of Diagnosis Information(DG1) to this message.
	 * @param objDG1SegmentCollection Collection of Diagnosis Information(DG1) to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addDiagnosisInformationSegment(ISingleCollection<DG1> objDG1SegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objDG1SegmentCollection;
		addSegment(EnumSegments.HL7_SEG_DG1, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Diagnosis Information(DG1) present in this message.
	 * @return ISingleCollection<DG1> - Collection of Diagnosis Information(DG1) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<DG1> getDiagnosisInformationSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_DG1);
		return (ISingleCollection<DG1>)objSegmentCollection;
	}

	/**
	 * Retrieves Diagnosis Related Group(DRG ) segment present in this message.
	 * @return DRG  - Diagnosis Related Group Segment present in this message or null if unavailable.
	 */
	public DRG  getDiagnosisRelatedGroupSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_DRG);
		if(objSingleCollection != null)
			return (DRG)objSingleCollection.elementAt(0);
		return null;
	}
	/**
	 * Sets value of Diagnosis Related Group segment for this message,overwrites if already present.
	 * @param objDRG Specified DRG Segment 
	 */
	public void setDiagnosisRelatedGroupSegment(DRG objDRG)
	{
		setSegment(EnumSegments.HL7_SEG_DRG,objDRG);
	}

	/**
	 * Adds Guarantor(GT1) to this message.
	 * @param objGT1 Specified Guarantor Segment to this message.
	 */
	public void addGuarantorSegment(GT1 objGT1)
	{
		addSegment(EnumSegments.HL7_SEG_GT1, objGT1);
	}

	/**
	 * Adds collection of Guarantor(GT1) to this message.
	 * @param objGT1SegmentCollection Collection of Guarantor(GT1) to add in this message
	 */
	@SuppressWarnings("unchecked")
	public void addGuarantorSegment(ISingleCollection<GT1> objGT1SegmentCollection)
	{
		ISingleCollection<?> objSegmentCollection = objGT1SegmentCollection;
		addSegment(EnumSegments.HL7_SEG_GT1, (ISingleCollection<ISegment>)objSegmentCollection);
	}

	/**
	 * Retrieves Collection of Guarantor(GT1) present in this message.
	 * @return ISingleCollection<GT1> - Collection of Guarantor(GT1) present in this message.
	 */
	@SuppressWarnings("unchecked")
	public ISingleCollection<GT1> getGuarantorSegments()
	{
		ISingleCollection<?> objSegmentCollection = getSegment(EnumSegments.HL7_SEG_GT1);
		return (ISingleCollection<GT1>)objSegmentCollection;
	}

	/**
	 * Retrieves Collection of Insurance GROUP present in this message.
	 * @return ISingleCollection<Group> - Collection of Insurance Group present 
	 */
	public ISingleCollection<IGroup> getInsuranceGroups()
	{
		return getGroup(EnumSegments.HL7_GROUP_INSURANCE);
	}

	/**
	 * Adds Collection of Insurance GROUP to this message.
	 * @param objSingleCollection Specified  Insurance GROUP Collection.
	 */
	public void addInsuranceGroups(ISingleCollection<IGroup> objSingleCollection)
	{
		addGroup(EnumSegments.HL7_GROUP_INSURANCE, objSingleCollection);
	}

	/**
	 * Adds Insurance GROUP to this message.
	 * @param objGroup Specified Insurance GROUP. 
	 */
	public void addInsuranceGroup(IGroup objGroup)
	{
		addGroup(EnumSegments.HL7_GROUP_INSURANCE, objGroup);
	}

	/**
	 * Retrieves Accident Information segment(ACC) present in this message.
	 * @return ACC - the Accident Information(ACC) Segment. present in this message or null if unavailable.
	 */
	public ACC getAccidentInformationSegment()
	{
		ISingleCollection<ISegment> objSingleCollection = getSegment(EnumSegments.HL7_SEG_ACC);
		if(objSingleCollection != null)
			return (ACC)objSingleCollection.elementAt(0);
		return null;
	}

	/**
	 * Sets value of Accident Information segment(ACC) for this message,overwrites if already present.
	 * @param objACC Specified Accident Information(ACC) Segment. 
	 */
	public void setAccidentInformationSegment(ACC objACC)
	{
		setSegment(EnumSegments.HL7_SEG_ACC,objACC);
	}	
}