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

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.enums.EnumCodingSchemeDesignator;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cm.EnumCM_FollicleMeasurementGroup;
import cdac.medinfo.sdk.dcm30_04.templates.enums.cv.EnumCV_FollicleMeasurementGroup;
import cdac.medinfo.sdk.dcm30_04.templates.generaltemplates.Measurement_TID300;
import cdac.medinfo.sdk.dcm30_04.templates.generaltemplates.Template;

/**
 * This class represents FollicleMeasurementGroup - TID5014
 */
public class FollicleMeasurementGroup_TID5014 extends Template
{
	/**
	 * Object of Measurement_TID300
	 */

	private Measurement_TID300 objMeasurement_TID300;
	/**
	 * Instantiates FollicleMeasurementGroup_TID5014 Template.
	 * @param objTree Object of SRTree.
	 */
	public FollicleMeasurementGroup_TID5014(SRTree objTree)
	{
		super(objTree);
	}
	/**
	 * Retrieves the object of Measurement_TID300
	 * @return objMeasurement_TID300 object of Measurement_TID300
	 */
	public Measurement_TID300 getMeasurement() 
	{
		if(null == objMeasurement_TID300)
			objMeasurement_TID300 = new Measurement_TID300(getSRTree());
		return objMeasurement_TID300;
	}
	/**
	 * Sets the value for Measurement Group
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param enumContinuityOfContent Enumerated Value for ContinuityOfContent.
	 */
	public void setMeasurementGroup(int[] arrPosition, EnumContinuityOfContent enumContinuityOfContent)
	{
		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_FollicleMeasurementGroup.MEASUREMENT_GROUP.getValue();
		String strCodeValue = EnumCV_FollicleMeasurementGroup.MEASUREMENT_GROUP_125007.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 Identifier
	 * @param arrPosition Identifier which shows the position of the node in the SR Tree.
	 * @param strIdentifier String value for Identifier.
	 */
	public void setIdentifier(int[] arrPosition, String strIdentifier)
	{
		/**
		 * Retrieves the corresponding values of CodeMeaning,CodeValue and CodingSchemeDesignator.
		 */
		String strCodeMeaning = EnumCM_FollicleMeasurementGroup.IDENTIFIER.getValue();
		String strCodeValue = EnumCV_FollicleMeasurementGroup.IDENTIFIER_12510.getValue();
		String strCSD = EnumCodingSchemeDesignator.DCM.getValue();

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