/*******************************************************************************
 *  Copyright 2017-2018 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.dcm30_04.templates.cid;


import cdac.medinfo.sdk.dcm30_04.templates.dicomsnomedmap.EnumChestCardiacSNOMEDMap;
import cdac.medinfo.sdk.dcm30_04.templates.enums.EnumCodingSchemeDesignator;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_Pacing;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cv.EnumCV_Pacing;


/**
 * This class represents Pacing - CID3555
 */
public class Pacing_CID3555  
{
	
	/**
	 * The Code Value for template.
	 */
	private String strCodeValue = null;
	
	/**
	 * The Code Meaning for template.
	 */
	private String strCodeMeaning = null;
	
	/**
	 * The Coding Scheme Designator for template.
	 */
	private String strCodingSchemeDesignator;
	/**
	 * The SNOMED CT ID for template.
	 */
	private String strSNOMEDCTID = null;	
	/**
	 * Instantiates a new Pacing_CID3555 Template 
	 */
	public Pacing_CID3555()
	{
		
	}
	
	/**
	 * Retrieves the value for Code Meaning.
	 * @return String value for Code Meaning.
	 */
	public String getCodeMeaning()
	{
		return strCodeMeaning;
	}

	/**
	 * Retrieves the value for Code Value.
	 * @return String value for Code Value.
	 */
	public String getCodeValue() 
	{
		return strCodeValue;
	}

	/**
	 * Retrieves the value for Coding Scheme Designator.
	 * @return String value for Coding Scheme Designator.
	 */
	public String getCodingSchemeDesignator() 
	{
		return strCodingSchemeDesignator;
	}
	/**
	 * Retrieves the value for SNOMED-CT ID.
	 * @return String value for SNOMED-CT ID.
	 */
	public String getSNOMEDCTID() 
	{
		return strSNOMEDCTID;
	}	
	/**
	 * Sets the Code Value according to Code Meaning.
	 * @param enumActionsWithConsumables Object of EnumActionsWithConsumables represents Code Meaning.
	 */
	private void setCodeValue(EnumCM_Pacing enumPacing)
	{
		switch(enumPacing)
		{
		case ATRIAL_PACING:
			this.strCodeValue = EnumCV_Pacing.ATRIAL_PACING_P2_35200.getValue();
			break;
		case AV_SEQUENTIAL_PACING:
			this.strCodeValue = EnumCV_Pacing.AV_SEQUENTIAL_PACING_R_002D9.getValue();
			break;
		case PACING:
			this.strCodeValue = EnumCV_Pacing.PACING_P2_35000.getValue();
			break;
		case PACING_WITH_MAGNET:
			this.strCodeValue = EnumCV_Pacing.PACING_WITH_MAGNET_R_00315.getValue();
			break;
		case TEMPORARY_TRANSCUTANEOUS_PACING:
			this.strCodeValue = EnumCV_Pacing.TEMPORARY_TRANSCUTANEOUS_PACING_P2_35440.getValue();
			break;
		case VENTRICULAR_PACING:
			this.strCodeValue = EnumCV_Pacing.VENTRICULAR_PACING_P2_35002.getValue();
			break;
		}
	}
	/**
	 * Sets the SNOMED-CT ID.
	 * @param enumPacing Object of EnumCM_Pacing represents Code Meaning.
	 */
	private void setSNOMEDCTID(EnumCM_Pacing enumPacing)
	{
		switch(enumPacing)
		{
		case PACING : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.PACING.getSNOMEDCTID(); break;
		case PACING_WITH_MAGNET : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.PACING_WITH_MAGNET.getSNOMEDCTID(); break;
		case ATRIAL_PACING : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.ATRIAL_PACING.getSNOMEDCTID(); break;
		case VENTRICULAR_PACING : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.VENTRICULAR_PACING.getSNOMEDCTID(); break;
		case AV_SEQUENTIAL_PACING : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.AV_SEQUENTIAL_PACING.getSNOMEDCTID(); break;
		case TEMPORARY_TRANSCUTANEOUS_PACING : this.strSNOMEDCTID =EnumChestCardiacSNOMEDMap.TEMPORARY_TRANSCUTANEOUS_PACING.getSNOMEDCTID(); break;
		}
	}

	/**
	 * Sets the value for Pacing
	 * @param enumPacing Object of EnumCM_Pacing.
	 */
	public void setPacing(EnumCM_Pacing enumPacing)
	{
		this.strCodeMeaning = enumPacing.getValue();
		this.strCodingSchemeDesignator = EnumCodingSchemeDesignator.SRT.getValue();
		setCodeValue(enumPacing);
		/**
		 * set SNOMED-CT ID
		 */
		setSNOMEDCTID(enumPacing);
	}
}
