/*******************************************************************************
 *  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.EnumDICOMSNOMEDMap;
import cdac.medinfo.sdk.dcm30_04.templates.enums.EnumCodingSchemeDesignator;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_AbnormalLucencyFindingOrFeature;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_OrganizationalRoles;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cv.EnumCV_OrganizationalRoles;


/**
 * This class represents OrganizationalRoles - CID7452
 */
public class OrganizationalRoles_CID7452  
{
	
	
	/**
	 * 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;
	
	/**
	 * Instantiates a new OrganizationalRoles_CID7452 Template 
	 */
	public OrganizationalRoles_CID7452()
	{
		
	}

	/**
	 * The SNOMED CT ID for template.
	 */
	private String strSNOMEDCTID = null;
	
	/**
	 * 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 enumOrganizationalRoles Object of OrganizationalRoles represents Code Meaning.
	 */
	private void setCodeValue(EnumCM_OrganizationalRoles enumOrganizationalRoles)
	{
		switch(enumOrganizationalRoles)
		{
		case MEDICAL_PRACTITIONER: this.strCodeValue =EnumCV_OrganizationalRoles.MEDICAL_PRACTITIONER_J_0016E.getValue(); break;
		case PHYSICIAN: this.strCodeValue =EnumCV_OrganizationalRoles.PHYSICIAN_J_004E8.getValue(); break;
		case NURSE: this.strCodeValue =EnumCV_OrganizationalRoles.NURSE_J_07100.getValue(); break;
		case RADIOLOGIC_TECHNOLOGIST: this.strCodeValue =EnumCV_OrganizationalRoles.RADIOLOGIC_TECHNOLOGIST_J_00187.getValue(); break;
		case RADIOGRAPHER: this.strCodeValue =EnumCV_OrganizationalRoles.RADIOGRAPHER_J_00187.getValue(); break;
		case INTERN: this.strCodeValue =EnumCV_OrganizationalRoles.INTERN_C1144859.getValue(); break;
		case RESIDENT: this.strCodeValue =EnumCV_OrganizationalRoles.RESIDENT_J_005E6.getValue(); break;
		case REGISTRAR: this.strCodeValue =EnumCV_OrganizationalRoles.REGISTRAR_J_00172.getValue(); break;
		case FELLOW: this.strCodeValue =EnumCV_OrganizationalRoles.FELLOW_121088.getValue(); break;
		case ATTENDING: this.strCodeValue =EnumCV_OrganizationalRoles.ATTENDING_J_005E8.getValue(); break;
		case CONSULTANT: this.strCodeValue =EnumCV_OrganizationalRoles.CONSULTANT_J_0050A.getValue(); break;
		case CONSULTING_PHYSICIAN: this.strCodeValue =EnumCV_OrganizationalRoles.CONSULTING_PHYSICIAN_C1441532.getValue(); break;
		case SCRUB_NURSE: this.strCodeValue =EnumCV_OrganizationalRoles.SCRUB_NURSE_J_0714A.getValue(); break;
		case SURGEON: this.strCodeValue =EnumCV_OrganizationalRoles.SURGEON_J_00556.getValue(); break;
		case SONOLOGIST: this.strCodeValue =EnumCV_OrganizationalRoles.SONOLOGIST_121092.getValue(); break;
		case SONOGRAPHER: this.strCodeValue =EnumCV_OrganizationalRoles.SONOGRAPHER_C1954848.getValue(); break;
		case RADIATION_PHYSICIST: this.strCodeValue =EnumCV_OrganizationalRoles.RADIATION_PHYSICIST_C2985483.getValue(); break;
		case MEDICAL_PHYSICIST: this.strCodeValue =EnumCV_OrganizationalRoles.MEDICAL_PHYSICIST_C1708969.getValue(); break;
		}
	}
	/**
	 * Sets the SNOMED-CT ID.
	 * @param enumOrganizationalRoles Object of EnumCM_OrganizationalRoles represents Code Meaning.
	 */
	private void setSNOMEDCTID(EnumCM_OrganizationalRoles enumOrganizationalRoles)
	{
		switch(enumOrganizationalRoles)
		{
		case MEDICAL_PRACTITIONER : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.MEDICAL_PRACTITIONER.getSNOMEDCTID(); break;
		case PHYSICIAN : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.PHYSICIAN.getSNOMEDCTID(); break;
		case NURSE : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.NURSE.getSNOMEDCTID(); break;
		case RADIOLOGIC_TECHNOLOGIST : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.RADIOLOGIC_TECHNOLOGIST.getSNOMEDCTID(); break;
		case RADIOGRAPHER : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.RADIOGRAPHER.getSNOMEDCTID(); break;
		case RESIDENT : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.RESIDENT.getSNOMEDCTID(); break;
		case REGISTRAR : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.REGISTRAR.getSNOMEDCTID(); break;
		case ATTENDING : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.ATTENDING.getSNOMEDCTID(); break;
		case CONSULTANT : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.CONSULTANT.getSNOMEDCTID(); break;
		case SCRUB_NURSE : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.SCRUB_NURSE.getSNOMEDCTID(); break;
		case SURGEON : this.strSNOMEDCTID =EnumDICOMSNOMEDMap.SURGEON.getSNOMEDCTID(); break;
		
		}
	}

	/**
	 * Sets the value for Organizational Roles
	 * @param enumOrganizationalRoles Object of EnumCM_OrganizationalRoles.
	 */
	public void setOrganizationalRoles(EnumCM_OrganizationalRoles enumOrganizationalRoles)
	{
		
		/**
		 * Retrieves the value for CodingSchemeDesignator, CodingSchemeVersion and Code Meaning and 
		 * sets the Code Value according to Code Meaning.
		 */
		this.strCodeMeaning = enumOrganizationalRoles.getValue();
		if(strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.FELLOW.getValue())
				|| strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.SONOLOGIST.getValue()))
			this.strCodingSchemeDesignator = EnumCodingSchemeDesignator.DCM.getValue();
		else if(strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.SONOGRAPHER.getValue())
				|| strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.RADIATION_PHYSICIST.getValue())
				|| strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.MEDICAL_PHYSICIST.getValue())
				|| strCodeMeaning.equalsIgnoreCase(EnumCM_OrganizationalRoles.CONSULTING_PHYSICIAN.getValue()))
			this.strCodingSchemeDesignator = EnumCodingSchemeDesignator.UMLS.getValue();
		else
			this.strCodingSchemeDesignator = EnumCodingSchemeDesignator.SRT.getValue();
		
		/**
		 * set code Value
		 */
	
		setCodeValue(enumOrganizationalRoles);
		/**
		 * set SNOMED-CT ID
		 */
		setSNOMEDCTID(enumOrganizationalRoles);
	}
}
