/FileExtraction/Java_unseen/IMS-MAXIMS_openMAXIMS/Source Library/openmaxims_workspace/ValueObjects/src/ims/clinicaladmin/vo/lookups/DementiaTermConfig.java
//#############################################################################
//#                                                                           #
//#  Copyright (C) <2015>  <IMS MAXIMS>                                       #
//#                                                                           #
//#  This program is free software: you can redistribute it and/or modify     #
//#  it under the terms of the GNU Affero General Public License as           #
//#  published by the Free Software Foundation, either version 3 of the       #
//#  License, or (at your option) any later version.                          # 
//#                                                                           #
//#  This program is distributed in the hope that it will be useful,          #
//#  but WITHOUT ANY WARRANTY; without even the implied warranty of           #
//#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            #
//#  GNU Affero General Public License for more details.                      #
//#                                                                           #
//#  You should have received a copy of the GNU Affero General Public License #
//#  along with this program.  If not, see <http://www.gnu.org/licenses/>.    #
//#                                                                           #
//#  IMS MAXIMS provides absolutely NO GUARANTEE OF THE CLINICAL SAFTEY of    #
//#  this program.  Users of this software do so entirely at their own risk.  #
//#  IMS MAXIMS only ensures the Clinical Safety of unaltered run-time        #
//#  software that it builds, deploys and maintains.                          #
//#                                                                           #
//#############################################################################
//#EOH
// This code was generated by Barbara Worwood using IMS Development Environment (version 1.80 build 5589.25814)
// Copyright (C) 1995-2015 IMS MAXIMS. All rights reserved.
// WARNING: DO NOT MODIFY the content of this file

package ims.clinicaladmin.vo.lookups;

import ims.framework.cn.data.TreeNode;
import java.util.ArrayList;
import ims.framework.utils.Image;
import ims.framework.utils.Color;

public class DementiaTermConfig extends ims.vo.LookupInstVo implements TreeNode
{
	private static final long serialVersionUID = 1L;

	public DementiaTermConfig()
	{
		super();
	}
	public DementiaTermConfig(int id)
	{
		super(id, "", true);
	}
	public DementiaTermConfig(int id, String text, boolean active)
	{
		super(id, text, active, null, null, null);
	}
	public DementiaTermConfig(int id, String text, boolean active, DementiaTermConfig parent, Image image)
	{
		super(id, text, active, parent, image);
	}
	public DementiaTermConfig(int id, String text, boolean active, DementiaTermConfig parent, Image image, Color color)
	{
		super(id, text, active, parent, image, color);
	}
	public DementiaTermConfig(int id, String text, boolean active, DementiaTermConfig parent, Image image, Color color, int order)
	{
		super(id, text, active, parent, image, color, order);
	}
	public static DementiaTermConfig buildLookup(ims.vo.LookupInstanceBean bean)
	{
		return new DementiaTermConfig(bean.getId(), bean.getText(), bean.isActive());
	}
	public String toString()
	{
		if(getText() != null)
			return getText();
		return "";
	}
	public TreeNode getParentNode()
	{
		return (DementiaTermConfig)super.getParentInstance();
	}
	public DementiaTermConfig getParent()
	{
		return (DementiaTermConfig)super.getParentInstance();
	}
	public void setParent(DementiaTermConfig parent)
	{
		super.setParentInstance(parent);
	}
	public TreeNode[] getChildren()
	{
		ArrayList children = super.getChildInstances();
		DementiaTermConfig[] typedChildren = new DementiaTermConfig[children.size()];
		for (int i = 0; i < children.size(); i++)
		{
			typedChildren[i] = (DementiaTermConfig)children.get(i);
		}
		return typedChildren;
	}
	public int addChild(TreeNode child)
	{
		if (child instanceof DementiaTermConfig)
		{
			super.addChild((DementiaTermConfig)child);
		}
		return super.getChildInstances().size();
	}
	public int removeChild(TreeNode child)
	{
		if (child instanceof DementiaTermConfig)
		{
			super.removeChild((DementiaTermConfig)child);
		}
		return super.getChildInstances().size();
	}
	public Image getExpandedImage()
	{
		return super.getImage();
	}
	public Image getCollapsedImage()
	{
		return super.getImage();
	}
	public static ims.framework.IItemCollection getNegativeInstancesAsIItemCollection()
	{
		DementiaTermConfigCollection result = new DementiaTermConfigCollection();
		result.add(AMTS_AGE);
		result.add(AMTS_DOB);
		result.add(AMTS_QUESTION);
		result.add(AMTS_CURRENT_YEAR);
		result.add(AMTS_CURRENT_TIME);
		result.add(AMTS_HOSP_NAME);
		result.add(AMTS_TWO_PEOPLE);
		result.add(AMTS_WW_TWO);
		result.add(AMTS_MONARCH);
		result.add(AMTS_COUNT);
		result.add(AMTS_RECALL_QUESTION);
		result.add(AMTS_TRUST_PROTOCOL);
		result.add(AMTS_MED_REVIEW);
		result.add(AMTS_FORM_HELP);
		result.add(AMTS_TRUST_PROTOCOL_TEXT);
		result.add(AMTS_MED_REVIEW_LABEL_TEXT);
		result.add(FIND_FORM_HELP);
		return result;
	}
	public static DementiaTermConfig[] getNegativeInstances()
	{
		DementiaTermConfig[] instances = new DementiaTermConfig[17];
		instances[0] = AMTS_AGE;
		instances[1] = AMTS_DOB;
		instances[2] = AMTS_QUESTION;
		instances[3] = AMTS_CURRENT_YEAR;
		instances[4] = AMTS_CURRENT_TIME;
		instances[5] = AMTS_HOSP_NAME;
		instances[6] = AMTS_TWO_PEOPLE;
		instances[7] = AMTS_WW_TWO;
		instances[8] = AMTS_MONARCH;
		instances[9] = AMTS_COUNT;
		instances[10] = AMTS_RECALL_QUESTION;
		instances[11] = AMTS_TRUST_PROTOCOL;
		instances[12] = AMTS_MED_REVIEW;
		instances[13] = AMTS_FORM_HELP;
		instances[14] = AMTS_TRUST_PROTOCOL_TEXT;
		instances[15] = AMTS_MED_REVIEW_LABEL_TEXT;
		instances[16] = FIND_FORM_HELP;
		return instances;
	}
	public static String[] getNegativeInstanceNames()
	{
		String[] negativeInstances = new String[17];
		negativeInstances[0] = "AMTS_AGE";
		negativeInstances[1] = "AMTS_DOB";
		negativeInstances[2] = "AMTS_QUESTION";
		negativeInstances[3] = "AMTS_CURRENT_YEAR";
		negativeInstances[4] = "AMTS_CURRENT_TIME";
		negativeInstances[5] = "AMTS_HOSP_NAME";
		negativeInstances[6] = "AMTS_TWO_PEOPLE";
		negativeInstances[7] = "AMTS_WW_TWO";
		negativeInstances[8] = "AMTS_MONARCH";
		negativeInstances[9] = "AMTS_COUNT";
		negativeInstances[10] = "AMTS_RECALL_QUESTION";
		negativeInstances[11] = "AMTS_TRUST_PROTOCOL";
		negativeInstances[12] = "AMTS_MED_REVIEW";
		negativeInstances[13] = "AMTS_FORM_HELP";
		negativeInstances[14] = "AMTS_TRUST_PROTOCOL_TEXT";
		negativeInstances[15] = "AMTS_MED_REVIEW_LABEL_TEXT";
		negativeInstances[16] = "FIND_FORM_HELP";
		return negativeInstances;
	}
	public static DementiaTermConfig getNegativeInstance(String name)
	{
		if(name == null)
			return null;
		String[] negativeInstances = getNegativeInstanceNames();
		for (int i = 0; i < negativeInstances.length; i++)
		{
			if(negativeInstances[i].equals(name))
				return getNegativeInstances()[i];
		}
		return null;
	}
	public static DementiaTermConfig getNegativeInstance(Integer id)
	{
		if(id == null)
			return null;
		DementiaTermConfig[] negativeInstances = getNegativeInstances();
		for (int i = 0; i < negativeInstances.length; i++)
		{
			if(negativeInstances[i].getID() == id)
				return negativeInstances[i];
		}
		return null;
	}
	public int getTypeId()
	{
		return TYPE_ID;
	}
	public static final int TYPE_ID = 1041002;
	public static final DementiaTermConfig AMTS_AGE = new DementiaTermConfig(-2448, "AMTS Age Term", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_DOB = new DementiaTermConfig(-2449, "AMTS DOB Term", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_QUESTION = new DementiaTermConfig(-2450, "AMTS Question to ask", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_CURRENT_YEAR = new DementiaTermConfig(-2451, "AMTS Current Year", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_CURRENT_TIME = new DementiaTermConfig(-2452, "AMTS Current Time", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_HOSP_NAME = new DementiaTermConfig(-2453, "AMTS Hospital Name", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_TWO_PEOPLE = new DementiaTermConfig(-2454, "AMTS 2 People", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_WW_TWO = new DementiaTermConfig(-2455, "AMTS WW2 ended", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_MONARCH = new DementiaTermConfig(-2456, "AMTS Monarch", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_COUNT = new DementiaTermConfig(-2457, "AMTS Count backward", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_RECALL_QUESTION = new DementiaTermConfig(-2458, "AMTS Recall Question", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_TRUST_PROTOCOL = new DementiaTermConfig(-2459, "AMTS Trust Protocol Help text", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_MED_REVIEW = new DementiaTermConfig(-2460, "AMTS Medication Review help text", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_FORM_HELP = new DementiaTermConfig(-2466, "AMTS Form Help text", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_TRUST_PROTOCOL_TEXT = new DementiaTermConfig(-2467, "AMTS Trust Protocol label text", true, null, null, Color.Default);
	public static final DementiaTermConfig AMTS_MED_REVIEW_LABEL_TEXT = new DementiaTermConfig(-2468, "AMTS Medication Review label text", true, null, null, Color.Default);
	public static final DementiaTermConfig FIND_FORM_HELP = new DementiaTermConfig(-2470, "FIND Form Help Text", true, null, null, Color.Default);
}
