/*******************************************************************************
 *  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.breastimagingreporttemplates;

import cdac.medinfo.sdk.dcm30_04.baselibs.ContentSequenceItem;
import cdac.medinfo.sdk.dcm30_04.enums.EnumContinuityOfContent;
import cdac.medinfo.sdk.dcm30_04.srtree.SRTree;
import cdac.medinfo.sdk.dcm30_04.templates.cid.YesNo_CID230;
import cdac.medinfo.sdk.dcm30_04.templates.enums.EnumCodingSchemeDesignator;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_BreastImagingReportSupplementaryData;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_YesNo;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cv.EnumCV_BreastImagingReportSupplementaryData;
import cdac.medinfo.sdk.dcm30_04.templates.generaltemplates.Template;

/**
 * This class represents BreastImagingReportSupplementaryData - TID4208
 */
public class BreastImagingReportSupplementaryData_TID4208 extends Template
{
	/**
	 * Object of BreastImagingAssessment_TID4203. 
	 */

	private BreastImagingAssessment_TID4203 objBreastImagingAssessmentTID4203 = null;

	/**
	 * Object of YesNo_CID230
	 */
	private YesNo_CID230 objYesNoCID230;

	/**
	 * Object of BreastImagingProcedureReported_TID4201. 
	 */

	private BreastImagingProcedureReported_TID4201 objBreastImagingProcedureReportedTID4201 = null;

	/**
	 * Object of BreastCompositionSection_TID4205. 
	 */

	private BreastCompositionSection_TID4205 objBreastCompositionSectionTID4205 = null;

	/**
	 * Object of BreastImagingReportFindingSection_TID4206. 
	 */

	private BreastImagingReportFindingSection_TID4206 objBreastImagingReportFindingSectionTID4206 = null;

	/**
	 * Object of BreastImagingReportInterventionSection_TID4204. 
	 */

	private BreastImagingReportInterventionSection_TID4204 objBreastImagingReportInterventionSectionTID4204 = null;

	/**
	 * Instantiates BreastImagingReportSupplementaryData_TID4208 Template.
	 * @param objTree Object of SRTree.
	 */
	public BreastImagingReportSupplementaryData_TID4208(SRTree objTree)
	{
		super(objTree);
	}

	/**
	 * Retrieves the object of BreastImagingAssessment.
	 * @return objBreastImagingProcedureReportedTID4201 object of BreastImagingAssessment_TID4203
	 */
	public BreastImagingAssessment_TID4203 getBreastImagingAssessment() 
	{
		if(null == this.objBreastImagingAssessmentTID4203)
			this.objBreastImagingAssessmentTID4203 = new BreastImagingAssessment_TID4203(getSRTree());
		return this.objBreastImagingAssessmentTID4203;
	}

	/**
	 * Retrieves the object of BreastCompositionSection.
	 * @return objBreastCompositionSectionTID4205 object of BreastCompositionSection_TID4205
	 */
	public BreastCompositionSection_TID4205 getBreastCompositionSection() 
	{
		if(null == this.objBreastCompositionSectionTID4205)
			this.objBreastCompositionSectionTID4205 = new BreastCompositionSection_TID4205(getSRTree());
		return this.objBreastCompositionSectionTID4205;
	}

	/**
	 * Retrieves the object of BreastImagingReportFindingSection.
	 * @return objBreastImagingReportFindingSectionTID4206 object of BreastImagingReportFindingSection_TID4206
	 */
	public BreastImagingReportFindingSection_TID4206 getBreastImagingReportFindingSection() 
	{
		if(null == this.objBreastImagingReportFindingSectionTID4206)
			this.objBreastImagingReportFindingSectionTID4206 = new BreastImagingReportFindingSection_TID4206(getSRTree());
		return this.objBreastImagingReportFindingSectionTID4206;
	}

	/**
	 * Retrieves the object of BreastImagingReportInterventionSection.
	 * @return objBreastImagingReportInterventionSectionTID4204 object of BreastImagingReportInterventionSection_TID4204
	 */
	public BreastImagingReportInterventionSection_TID4204 getBreastImagingReportInterventionSection() 
	{
		if(null == this.objBreastImagingReportInterventionSectionTID4204)
			this.objBreastImagingReportInterventionSectionTID4204 = new BreastImagingReportInterventionSection_TID4204(getSRTree());
		return this.objBreastImagingReportInterventionSectionTID4204;
	}

	/**
	 * Retrieves the object of BreastImagingProcedureReported.
	 * @return objBreastImagingProcedureReportedTID4201 object of BreastImagingProcedureReported_TID4201
	 */
	public BreastImagingProcedureReported_TID4201 getBreastImagingProcedureReported() 
	{
		if(null == this.objBreastImagingProcedureReportedTID4201)
			this.objBreastImagingProcedureReportedTID4201 = new BreastImagingProcedureReported_TID4201(getSRTree());
		return this.objBreastImagingProcedureReportedTID4201;
	}

	/**
	 * Sets the value for Supplementary Data
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param enumContinuityOfContent Enumerated Value for ContinuityOfContent.
	 */
	public void setSupplementaryData(int[] arrPosition, EnumContinuityOfContent enumContinuityOfContent)
	{
		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_BreastImagingReportSupplementaryData.SUPPLEMENTARY_DATA.getValue();
		String strCodeValue = EnumCV_BreastImagingReportSupplementaryData.SUPPLEMENTARY_DATA_111414.getValue();
		String strCSD = EnumCodingSchemeDesignator.DCM.getValue();

		/**
		 * Creating a node of Value Type CONTAINER and adding this node at specified identifier in the SR Tree.
		 */
		ContentSequenceItem objContentSequenceItem = getSRTree().createContainer(arrPosition, strCodeMeaning, strCodeValue, strCSD, enumContinuityOfContent);
		getSRTree().addChild(objContentSequenceItem);
	}

	/**
	 * Sets the value for Baseline screening mammogram.
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param enumYesNo Enum value for Yes-No.
	 */
	public void setBaselineScreeningMammogram(int[] arrPosition, EnumCM_YesNo enumYesNo)
	{
		/**
		 * Sets the value for Primary Intervention Device.
		 */
		if(null== this.objYesNoCID230)
			this.objYesNoCID230 = new YesNo_CID230();
		this.objYesNoCID230.setYesNo(enumYesNo);

		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCM = this.objYesNoCID230.getCodeMeaning();
		String strCV = this.objYesNoCID230.getCodeValue();
		String strCSD1 = this.objYesNoCID230.getCodingSchemeDesignator();
		String strSNOMEDCTID = objYesNoCID230.getSNOMEDCTID();
		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_BreastImagingReportSupplementaryData.BASELINE_SCREENING_MAMMOGRAM.getValue();
		String strCodeValue = EnumCV_BreastImagingReportSupplementaryData.BASELINE_SCREENING_MAMMOGRAM_111403.getValue();
		String strCSD2 = EnumCodingSchemeDesignator.DCM.getValue();

		/**
		 * Creating a node of Value Type CODE and adding this node at specified identifier in the SR Tree.
		 */
		ContentSequenceItem objContentSequenceItem = getSRTree().createCodeNode(arrPosition, strCodeMeaning,strCodeValue , strCSD2, strCV, strCSD1, "", strCM,strSNOMEDCTID);
		getSRTree().addChild(objContentSequenceItem);
	}

	/**
	 * Sets the value for First mammogram ever.
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param enumYesNo Enum value for Yes-No.
	 */
	public void setFirstMammogramEver(int[] arrPosition, EnumCM_YesNo enumYesNo)
	{
		/**
		 * Sets the value for Primary Intervention Device.
		 */
		if(null== this.objYesNoCID230)
			this.objYesNoCID230 = new YesNo_CID230();
		this.objYesNoCID230.setYesNo(enumYesNo);

		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCM = this.objYesNoCID230.getCodeMeaning();
		String strCV = this.objYesNoCID230.getCodeValue();
		String strCSD1 = this.objYesNoCID230.getCodingSchemeDesignator();
		String strSNOMEDCTID = objYesNoCID230.getSNOMEDCTID();

		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_BreastImagingReportSupplementaryData.FIRST_MAMMOGRAM_EVER.getValue();
		String strCodeValue = EnumCV_BreastImagingReportSupplementaryData.FIRST_MAMMOGRAM_EVER_111404.getValue();
		String strCSD2 = EnumCodingSchemeDesignator.DCM.getValue();

		/**
		 * Creating a node of Value Type CODE and adding this node at specified identifier in the SR Tree.
		 */
		ContentSequenceItem objContentSequenceItem = getSRTree().createCodeNode(arrPosition, strCodeMeaning,strCodeValue , strCSD2, strCV, strCSD1, "", strCM,strSNOMEDCTID);
		getSRTree().addChild(objContentSequenceItem);
	}

	/**
	 * Sets the value for Overall Assessment
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param enumContinuityOfContent Enumerated Value for ContinuityOfContent.
	 */
	public void setOverallAssessment(int[] arrPosition, EnumContinuityOfContent enumContinuityOfContent)
	{
		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_BreastImagingReportSupplementaryData.OVERALL_ASSESSMENT.getValue();
		String strCodeValue = EnumCV_BreastImagingReportSupplementaryData.OVERALL_ASSESSMENT_111413.getValue();
		String strCSD = EnumCodingSchemeDesignator.DCM.getValue();

		/**
		 * Creating a node of Value Type CONTAINER and adding this node at specified identifier in the SR Tree.
		 */
		ContentSequenceItem objContentSequenceItem = getSRTree().createContainer(arrPosition, strCodeMeaning, strCodeValue, strCSD, enumContinuityOfContent);
		getSRTree().addChild(objContentSequenceItem);
	}
}
