/FileExtraction/Java_unseen/IMS-MAXIMS_openMAXIMS/Source Library/openmaxims_workspace/ValueObjects/src/ims/ocrr/vo/SpecimenWorkListitemCustomVo.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.ocrr.vo;


public class SpecimenWorkListitemCustomVo extends ims.vo.ValueObject implements ims.vo.ImsCloneable, Comparable
{
	private static final long serialVersionUID = 1L;

	public SpecimenWorkListitemCustomVo()
	{
	}
	public SpecimenWorkListitemCustomVo(ims.ocrr.vo.beans.SpecimenWorkListitemCustomVoBean bean)
	{
		this.worklistitemid = bean.getWorkListitemId();
		this.instructionstocollector = bean.getInstructionsToCollector();
		this.serviceid = bean.getServiceId();
		this.servicename = bean.getServiceName();
		this.investigation = bean.getInvestigation();
		this.patientid = bean.getPatientId();
		this.patientsurname = bean.getPatientSurname();
		this.patientforename = bean.getPatientForename();
		this.wardid = bean.getWardId();
		this.ward = bean.getWard();
		this.containerquantity = bean.getContainerQuantity();
		this.adultcontainer = bean.getAdultContainer();
		this.collectionstatus = bean.getCollectionStatus();
		this.collector = bean.getCollector();
		this.collectiondatetime = bean.getCollectionDateTime() == null ? null : bean.getCollectionDateTime().buildDateTime();
		this.collectioncomments = bean.getCollectionComments();
		this.collectingmos = bean.getCollectingMos();
		this.specimencontainerid = bean.getSpecimenContainerId();
		this.paediatriccontainer = bean.getPaediatricContainer();
		this.paediatriccontainerid = bean.getPaediatricContainerId();
		this.adultvolume = bean.getAdultVolume();
		this.paediatricvolume = bean.getPaediatricVolume();
		this.dftnooflabelsets = bean.getDftNoOfLabelSets();
		this.containeradultvolume = bean.getContainerAdultVolume();
		this.containerpaediatricvolume = bean.getContainerPaediatricVolume();
		this.orderspecimenid = bean.getOrderSpecimenId();
		this.placerordnum = bean.getPlacerOrdNum();
		this.orderinvestigationid = bean.getOrderInvestigationId();
	}
	public void populate(ims.vo.ValueObjectBeanMap map, ims.ocrr.vo.beans.SpecimenWorkListitemCustomVoBean bean)
	{
		this.worklistitemid = bean.getWorkListitemId();
		this.instructionstocollector = bean.getInstructionsToCollector();
		this.serviceid = bean.getServiceId();
		this.servicename = bean.getServiceName();
		this.investigation = bean.getInvestigation();
		this.patientid = bean.getPatientId();
		this.patientsurname = bean.getPatientSurname();
		this.patientforename = bean.getPatientForename();
		this.wardid = bean.getWardId();
		this.ward = bean.getWard();
		this.containerquantity = bean.getContainerQuantity();
		this.adultcontainer = bean.getAdultContainer();
		this.collectionstatus = bean.getCollectionStatus();
		this.collector = bean.getCollector();
		this.collectiondatetime = bean.getCollectionDateTime() == null ? null : bean.getCollectionDateTime().buildDateTime();
		this.collectioncomments = bean.getCollectionComments();
		this.collectingmos = bean.getCollectingMos();
		this.specimencontainerid = bean.getSpecimenContainerId();
		this.paediatriccontainer = bean.getPaediatricContainer();
		this.paediatriccontainerid = bean.getPaediatricContainerId();
		this.adultvolume = bean.getAdultVolume();
		this.paediatricvolume = bean.getPaediatricVolume();
		this.dftnooflabelsets = bean.getDftNoOfLabelSets();
		this.containeradultvolume = bean.getContainerAdultVolume();
		this.containerpaediatricvolume = bean.getContainerPaediatricVolume();
		this.orderspecimenid = bean.getOrderSpecimenId();
		this.placerordnum = bean.getPlacerOrdNum();
		this.orderinvestigationid = bean.getOrderInvestigationId();
	}
	public ims.vo.ValueObjectBean getBean()
	{
		return this.getBean(new ims.vo.ValueObjectBeanMap());
	}
	public ims.vo.ValueObjectBean getBean(ims.vo.ValueObjectBeanMap map)
	{
		ims.ocrr.vo.beans.SpecimenWorkListitemCustomVoBean bean = null;
		if(map != null)
			bean = (ims.ocrr.vo.beans.SpecimenWorkListitemCustomVoBean)map.getValueObjectBean(this);
		if (bean == null)
		{
			bean = new ims.ocrr.vo.beans.SpecimenWorkListitemCustomVoBean();
			map.addValueObjectBean(this, bean);
			bean.populate(map, this);
		}
		return bean;
	}
	public boolean getWorkListitemIdIsNotNull()
	{
		return this.worklistitemid != null;
	}
	public Integer getWorkListitemId()
	{
		return this.worklistitemid;
	}
	public void setWorkListitemId(Integer value)
	{
		this.isValidated = false;
		this.worklistitemid = value;
	}
	public boolean getInstructionsToCollectorIsNotNull()
	{
		return this.instructionstocollector != null;
	}
	public String getInstructionsToCollector()
	{
		return this.instructionstocollector;
	}
	public static int getInstructionsToCollectorMaxLength()
	{
		return 255;
	}
	public void setInstructionsToCollector(String value)
	{
		this.isValidated = false;
		this.instructionstocollector = value;
	}
	public boolean getServiceIdIsNotNull()
	{
		return this.serviceid != null;
	}
	public Integer getServiceId()
	{
		return this.serviceid;
	}
	public void setServiceId(Integer value)
	{
		this.isValidated = false;
		this.serviceid = value;
	}
	public boolean getServiceNameIsNotNull()
	{
		return this.servicename != null;
	}
	public String getServiceName()
	{
		return this.servicename;
	}
	public static int getServiceNameMaxLength()
	{
		return 255;
	}
	public void setServiceName(String value)
	{
		this.isValidated = false;
		this.servicename = value;
	}
	public boolean getInvestigationIsNotNull()
	{
		return this.investigation != null;
	}
	public String getInvestigation()
	{
		return this.investigation;
	}
	public static int getInvestigationMaxLength()
	{
		return 255;
	}
	public void setInvestigation(String value)
	{
		this.isValidated = false;
		this.investigation = value;
	}
	public boolean getPatientIdIsNotNull()
	{
		return this.patientid != null;
	}
	public Integer getPatientId()
	{
		return this.patientid;
	}
	public void setPatientId(Integer value)
	{
		this.isValidated = false;
		this.patientid = value;
	}
	public boolean getPatientSurnameIsNotNull()
	{
		return this.patientsurname != null;
	}
	public String getPatientSurname()
	{
		return this.patientsurname;
	}
	public static int getPatientSurnameMaxLength()
	{
		return 255;
	}
	public void setPatientSurname(String value)
	{
		this.isValidated = false;
		this.patientsurname = value;
	}
	public boolean getPatientForenameIsNotNull()
	{
		return this.patientforename != null;
	}
	public String getPatientForename()
	{
		return this.patientforename;
	}
	public static int getPatientForenameMaxLength()
	{
		return 255;
	}
	public void setPatientForename(String value)
	{
		this.isValidated = false;
		this.patientforename = value;
	}
	public boolean getWardIdIsNotNull()
	{
		return this.wardid != null;
	}
	public Integer getWardId()
	{
		return this.wardid;
	}
	public void setWardId(Integer value)
	{
		this.isValidated = false;
		this.wardid = value;
	}
	public boolean getWardIsNotNull()
	{
		return this.ward != null;
	}
	public String getWard()
	{
		return this.ward;
	}
	public static int getWardMaxLength()
	{
		return 255;
	}
	public void setWard(String value)
	{
		this.isValidated = false;
		this.ward = value;
	}
	public boolean getContainerQuantityIsNotNull()
	{
		return this.containerquantity != null;
	}
	public Integer getContainerQuantity()
	{
		return this.containerquantity;
	}
	public void setContainerQuantity(Integer value)
	{
		this.isValidated = false;
		this.containerquantity = value;
	}
	public boolean getAdultContainerIsNotNull()
	{
		return this.adultcontainer != null;
	}
	public String getAdultContainer()
	{
		return this.adultcontainer;
	}
	public static int getAdultContainerMaxLength()
	{
		return 255;
	}
	public void setAdultContainer(String value)
	{
		this.isValidated = false;
		this.adultcontainer = value;
	}
	public boolean getCollectionStatusIsNotNull()
	{
		return this.collectionstatus != null;
	}
	public Integer getCollectionStatus()
	{
		return this.collectionstatus;
	}
	public void setCollectionStatus(Integer value)
	{
		this.isValidated = false;
		this.collectionstatus = value;
	}
	public boolean getCollectorIsNotNull()
	{
		return this.collector != null;
	}
	public String getCollector()
	{
		return this.collector;
	}
	public static int getCollectorMaxLength()
	{
		return 255;
	}
	public void setCollector(String value)
	{
		this.isValidated = false;
		this.collector = value;
	}
	public boolean getCollectionDateTimeIsNotNull()
	{
		return this.collectiondatetime != null;
	}
	public ims.framework.utils.DateTime getCollectionDateTime()
	{
		return this.collectiondatetime;
	}
	public void setCollectionDateTime(ims.framework.utils.DateTime value)
	{
		this.isValidated = false;
		this.collectiondatetime = value;
	}
	public boolean getCollectionCommentsIsNotNull()
	{
		return this.collectioncomments != null;
	}
	public String getCollectionComments()
	{
		return this.collectioncomments;
	}
	public static int getCollectionCommentsMaxLength()
	{
		return 255;
	}
	public void setCollectionComments(String value)
	{
		this.isValidated = false;
		this.collectioncomments = value;
	}
	public boolean getCollectingMosIsNotNull()
	{
		return this.collectingmos != null;
	}
	public Integer getCollectingMos()
	{
		return this.collectingmos;
	}
	public void setCollectingMos(Integer value)
	{
		this.isValidated = false;
		this.collectingmos = value;
	}
	public boolean getSpecimenContainerIdIsNotNull()
	{
		return this.specimencontainerid != null;
	}
	public Integer getSpecimenContainerId()
	{
		return this.specimencontainerid;
	}
	public void setSpecimenContainerId(Integer value)
	{
		this.isValidated = false;
		this.specimencontainerid = value;
	}
	public boolean getPaediatricContainerIsNotNull()
	{
		return this.paediatriccontainer != null;
	}
	public String getPaediatricContainer()
	{
		return this.paediatriccontainer;
	}
	public static int getPaediatricContainerMaxLength()
	{
		return 255;
	}
	public void setPaediatricContainer(String value)
	{
		this.isValidated = false;
		this.paediatriccontainer = value;
	}
	public boolean getPaediatricContainerIdIsNotNull()
	{
		return this.paediatriccontainerid != null;
	}
	public Integer getPaediatricContainerId()
	{
		return this.paediatriccontainerid;
	}
	public void setPaediatricContainerId(Integer value)
	{
		this.isValidated = false;
		this.paediatriccontainerid = value;
	}
	public boolean getAdultVolumeIsNotNull()
	{
		return this.adultvolume != null;
	}
	public Float getAdultVolume()
	{
		return this.adultvolume;
	}
	public void setAdultVolume(Float value)
	{
		this.isValidated = false;
		this.adultvolume = value;
	}
	public boolean getPaediatricVolumeIsNotNull()
	{
		return this.paediatricvolume != null;
	}
	public Float getPaediatricVolume()
	{
		return this.paediatricvolume;
	}
	public void setPaediatricVolume(Float value)
	{
		this.isValidated = false;
		this.paediatricvolume = value;
	}
	public boolean getDftNoOfLabelSetsIsNotNull()
	{
		return this.dftnooflabelsets != null;
	}
	public Integer getDftNoOfLabelSets()
	{
		return this.dftnooflabelsets;
	}
	public void setDftNoOfLabelSets(Integer value)
	{
		this.isValidated = false;
		this.dftnooflabelsets = value;
	}
	public boolean getContainerAdultVolumeIsNotNull()
	{
		return this.containeradultvolume != null;
	}
	public Float getContainerAdultVolume()
	{
		return this.containeradultvolume;
	}
	public void setContainerAdultVolume(Float value)
	{
		this.isValidated = false;
		this.containeradultvolume = value;
	}
	public boolean getContainerPaediatricVolumeIsNotNull()
	{
		return this.containerpaediatricvolume != null;
	}
	public Float getContainerPaediatricVolume()
	{
		return this.containerpaediatricvolume;
	}
	public void setContainerPaediatricVolume(Float value)
	{
		this.isValidated = false;
		this.containerpaediatricvolume = value;
	}
	public boolean getOrderSpecimenIdIsNotNull()
	{
		return this.orderspecimenid != null;
	}
	public Integer getOrderSpecimenId()
	{
		return this.orderspecimenid;
	}
	public void setOrderSpecimenId(Integer value)
	{
		this.isValidated = false;
		this.orderspecimenid = value;
	}
	public boolean getPlacerOrdNumIsNotNull()
	{
		return this.placerordnum != null;
	}
	public String getPlacerOrdNum()
	{
		return this.placerordnum;
	}
	public static int getPlacerOrdNumMaxLength()
	{
		return 255;
	}
	public void setPlacerOrdNum(String value)
	{
		this.isValidated = false;
		this.placerordnum = value;
	}
	public boolean getOrderInvestigationIdIsNotNull()
	{
		return this.orderinvestigationid != null;
	}
	public Integer getOrderInvestigationId()
	{
		return this.orderinvestigationid;
	}
	public void setOrderInvestigationId(Integer value)
	{
		this.isValidated = false;
		this.orderinvestigationid = value;
	}
	public final String getIItemText()
	{
		return toString();
	}
	public final Integer getBoId() 
	{
		return null;
	}
	public final String getBoClassName()
	{
		return null;
	}
	public boolean equals(Object obj)
	{
		if(obj == null)
			return false;
		if(!(obj instanceof SpecimenWorkListitemCustomVo))
			return false;
		SpecimenWorkListitemCustomVo compareObj = (SpecimenWorkListitemCustomVo)obj;
		if(this.getWorkListitemId() == null && compareObj.getWorkListitemId() != null)
			return false;
		if(this.getWorkListitemId() != null && compareObj.getWorkListitemId() == null)
			return false;
		if(this.getWorkListitemId() != null && compareObj.getWorkListitemId() != null)
			if(!this.getWorkListitemId().equals(compareObj.getWorkListitemId()))
				return false;
		if(this.getInstructionsToCollector() == null && compareObj.getInstructionsToCollector() != null)
			return false;
		if(this.getInstructionsToCollector() != null && compareObj.getInstructionsToCollector() == null)
			return false;
		if(this.getInstructionsToCollector() != null && compareObj.getInstructionsToCollector() != null)
			if(!this.getInstructionsToCollector().equals(compareObj.getInstructionsToCollector()))
				return false;
		if(this.getServiceId() == null && compareObj.getServiceId() != null)
			return false;
		if(this.getServiceId() != null && compareObj.getServiceId() == null)
			return false;
		if(this.getServiceId() != null && compareObj.getServiceId() != null)
			if(!this.getServiceId().equals(compareObj.getServiceId()))
				return false;
		if(this.getPatientId() == null && compareObj.getPatientId() != null)
			return false;
		if(this.getPatientId() != null && compareObj.getPatientId() == null)
			return false;
		if(this.getPatientId() != null && compareObj.getPatientId() != null)
			if(!this.getPatientId().equals(compareObj.getPatientId()))
				return false;
		if(this.getWardId() == null && compareObj.getWardId() != null)
			return false;
		if(this.getWardId() != null && compareObj.getWardId() == null)
			return false;
		if(this.getWardId() != null && compareObj.getWardId() != null)
			if(!this.getWardId().equals(compareObj.getWardId()))
				return false;
		if(this.getContainerQuantity() == null && compareObj.getContainerQuantity() != null)
			return false;
		if(this.getContainerQuantity() != null && compareObj.getContainerQuantity() == null)
			return false;
		if(this.getContainerQuantity() != null && compareObj.getContainerQuantity() != null)
			if(!this.getContainerQuantity().equals(compareObj.getContainerQuantity()))
				return false;
		if(this.getCollectionStatus() == null && compareObj.getCollectionStatus() != null)
			return false;
		if(this.getCollectionStatus() != null && compareObj.getCollectionStatus() == null)
			return false;
		if(this.getCollectionStatus() != null && compareObj.getCollectionStatus() != null)
			if(!this.getCollectionStatus().equals(compareObj.getCollectionStatus()))
				return false;
		if(this.getCollector() == null && compareObj.getCollector() != null)
			return false;
		if(this.getCollector() != null && compareObj.getCollector() == null)
			return false;
		if(this.getCollector() != null && compareObj.getCollector() != null)
			if(!this.getCollector().equals(compareObj.getCollector()))
				return false;
		if(this.getCollectionDateTime() == null && compareObj.getCollectionDateTime() != null)
			return false;
		if(this.getCollectionDateTime() != null && compareObj.getCollectionDateTime() == null)
			return false;
		if(this.getCollectionDateTime() != null && compareObj.getCollectionDateTime() != null)
			if(!this.getCollectionDateTime().equals(compareObj.getCollectionDateTime()))
				return false;
		if(this.getCollectionComments() == null && compareObj.getCollectionComments() != null)
			return false;
		if(this.getCollectionComments() != null && compareObj.getCollectionComments() == null)
			return false;
		if(this.getCollectionComments() != null && compareObj.getCollectionComments() != null)
			if(!this.getCollectionComments().equals(compareObj.getCollectionComments()))
				return false;
		if(this.getCollectingMos() == null && compareObj.getCollectingMos() != null)
			return false;
		if(this.getCollectingMos() != null && compareObj.getCollectingMos() == null)
			return false;
		if(this.getCollectingMos() != null && compareObj.getCollectingMos() != null)
			if(!this.getCollectingMos().equals(compareObj.getCollectingMos()))
				return false;
		if(this.getInvestigation() == null && compareObj.getInvestigation() != null)
			return false;
		if(this.getInvestigation() != null && compareObj.getInvestigation() == null)
			return false;
		if(this.getInvestigation() != null && compareObj.getInvestigation() != null)
			if(!this.getInvestigation().equals(compareObj.getInvestigation()))
				return false;
		if(this.getSpecimenContainerId() == null && compareObj.getSpecimenContainerId() != null)
			return false;
		if(this.getSpecimenContainerId() != null && compareObj.getSpecimenContainerId() == null)
			return false;
		if(this.getSpecimenContainerId() != null && compareObj.getSpecimenContainerId() != null)
			if(!this.getSpecimenContainerId().equals(compareObj.getSpecimenContainerId()))
				return false;
		if(this.getAdultContainer() == null && compareObj.getAdultContainer() != null)
			return false;
		if(this.getAdultContainer() != null && compareObj.getAdultContainer() == null)
			return false;
		if(this.getAdultContainer() != null && compareObj.getAdultContainer() != null)
			if(!this.getAdultContainer().equals(compareObj.getAdultContainer()))
				return false;
		if(this.getPaediatricContainer() == null && compareObj.getPaediatricContainer() != null)
			return false;
		if(this.getPaediatricContainer() != null && compareObj.getPaediatricContainer() == null)
			return false;
		if(this.getPaediatricContainer() != null && compareObj.getPaediatricContainer() != null)
			if(!this.getPaediatricContainer().equals(compareObj.getPaediatricContainer()))
				return false;
		if(this.getAdultVolume() == null && compareObj.getAdultVolume() != null)
			return false;
		if(this.getAdultVolume() != null && compareObj.getAdultVolume() == null)
			return false;
		if(this.getAdultVolume() != null && compareObj.getAdultVolume() != null)
			if(!this.getAdultVolume().equals(compareObj.getAdultVolume()))
				return false;
		if(this.getPaediatricVolume() == null && compareObj.getPaediatricVolume() != null)
			return false;
		if(this.getPaediatricVolume() != null && compareObj.getPaediatricVolume() == null)
			return false;
		if(this.getPaediatricVolume() != null && compareObj.getPaediatricVolume() != null)
			if(!this.getPaediatricVolume().equals(compareObj.getPaediatricVolume()))
				return false;
		if(this.getPaediatricContainerId() == null && compareObj.getPaediatricContainerId() != null)
			return false;
		if(this.getPaediatricContainerId() != null && compareObj.getPaediatricContainerId() == null)
			return false;
		if(this.getPaediatricContainerId() != null && compareObj.getPaediatricContainerId() != null)
			return this.getPaediatricContainerId().equals(compareObj.getPaediatricContainerId());
		return super.equals(obj);
	}
	public boolean isValidated()
	{
		if(this.isBusy)
			return true;
		this.isBusy = true;
	
		if(!this.isValidated)
		{
			this.isBusy = false;
			return false;
		}
		this.isBusy = false;
		return true;
	}
	public String[] validate()
	{
		return validate(null);
	}
	public String[] validate(String[] existingErrors)
	{
		if(this.isBusy)
			return null;
		this.isBusy = true;
	
		java.util.ArrayList<String> listOfErrors = new java.util.ArrayList<String>();
		if(existingErrors != null)
		{
			for(int x = 0; x < existingErrors.length; x++)
			{
				listOfErrors.add(existingErrors[x]);
			}
		}
		int errorCount = listOfErrors.size();
		if(errorCount == 0)
		{
			this.isBusy = false;
			this.isValidated = true;
			return null;
		}
		String[] result = new String[errorCount];
		for(int x = 0; x < errorCount; x++)
			result[x] = (String)listOfErrors.get(x);
		this.isBusy = false;
		this.isValidated = false;
		return result;
	}
	public Object clone()
	{
		if(this.isBusy)
			return this;
		this.isBusy = true;
	
		SpecimenWorkListitemCustomVo clone = new SpecimenWorkListitemCustomVo();
		
		clone.worklistitemid = this.worklistitemid;
		clone.instructionstocollector = this.instructionstocollector;
		clone.serviceid = this.serviceid;
		clone.servicename = this.servicename;
		clone.investigation = this.investigation;
		clone.patientid = this.patientid;
		clone.patientsurname = this.patientsurname;
		clone.patientforename = this.patientforename;
		clone.wardid = this.wardid;
		clone.ward = this.ward;
		clone.containerquantity = this.containerquantity;
		clone.adultcontainer = this.adultcontainer;
		clone.collectionstatus = this.collectionstatus;
		clone.collector = this.collector;
		if(this.collectiondatetime == null)
			clone.collectiondatetime = null;
		else
			clone.collectiondatetime = (ims.framework.utils.DateTime)this.collectiondatetime.clone();
		clone.collectioncomments = this.collectioncomments;
		clone.collectingmos = this.collectingmos;
		clone.specimencontainerid = this.specimencontainerid;
		clone.paediatriccontainer = this.paediatriccontainer;
		clone.paediatriccontainerid = this.paediatriccontainerid;
		clone.adultvolume = this.adultvolume;
		clone.paediatricvolume = this.paediatricvolume;
		clone.dftnooflabelsets = this.dftnooflabelsets;
		clone.containeradultvolume = this.containeradultvolume;
		clone.containerpaediatricvolume = this.containerpaediatricvolume;
		clone.orderspecimenid = this.orderspecimenid;
		clone.placerordnum = this.placerordnum;
		clone.orderinvestigationid = this.orderinvestigationid;
		clone.isValidated = this.isValidated;
		
		this.isBusy = false;
		return clone;
	}
	public int compareTo(Object obj)
	{
		return compareTo(obj, true);
	}
	public int compareTo(Object obj, boolean caseInsensitive)
	{
		if (obj == null)
		{
			return -1;
		}
		if(caseInsensitive); // this is to avoid eclipse warning only.
		if (!(SpecimenWorkListitemCustomVo.class.isAssignableFrom(obj.getClass())))
		{
			throw new ClassCastException("A SpecimenWorkListitemCustomVo object cannot be compared an Object of type " + obj.getClass().getName());
		}
		SpecimenWorkListitemCustomVo compareObj = (SpecimenWorkListitemCustomVo)obj;
		int retVal = 0;
		if (retVal == 0)
		{
			if(this.getWorkListitemId() == null && compareObj.getWorkListitemId() != null)
				return -1;
			if(this.getWorkListitemId() != null && compareObj.getWorkListitemId() == null)
				return 1;
			if(this.getWorkListitemId() != null && compareObj.getWorkListitemId() != null)
				retVal = this.getWorkListitemId().compareTo(compareObj.getWorkListitemId());
		}
		return retVal;
	}
	public synchronized static int generateValueObjectUniqueID()
	{
		return ims.vo.ValueObject.generateUniqueID();
	}
	public int countFieldsWithValue()
	{
		int count = 0;
		if(this.worklistitemid != null)
			count++;
		if(this.instructionstocollector != null)
			count++;
		if(this.serviceid != null)
			count++;
		if(this.servicename != null)
			count++;
		if(this.investigation != null)
			count++;
		if(this.patientid != null)
			count++;
		if(this.patientsurname != null)
			count++;
		if(this.patientforename != null)
			count++;
		if(this.wardid != null)
			count++;
		if(this.ward != null)
			count++;
		if(this.containerquantity != null)
			count++;
		if(this.adultcontainer != null)
			count++;
		if(this.collectionstatus != null)
			count++;
		if(this.collector != null)
			count++;
		if(this.collectiondatetime != null)
			count++;
		if(this.collectioncomments != null)
			count++;
		if(this.collectingmos != null)
			count++;
		if(this.specimencontainerid != null)
			count++;
		if(this.paediatriccontainer != null)
			count++;
		if(this.paediatriccontainerid != null)
			count++;
		if(this.adultvolume != null)
			count++;
		if(this.paediatricvolume != null)
			count++;
		if(this.dftnooflabelsets != null)
			count++;
		if(this.containeradultvolume != null)
			count++;
		if(this.containerpaediatricvolume != null)
			count++;
		if(this.orderspecimenid != null)
			count++;
		if(this.placerordnum != null)
			count++;
		if(this.orderinvestigationid != null)
			count++;
		return count;
	}
	public int countValueObjectFields()
	{
		return 28;
	}
	protected Integer worklistitemid;
	protected String instructionstocollector;
	protected Integer serviceid;
	protected String servicename;
	protected String investigation;
	protected Integer patientid;
	protected String patientsurname;
	protected String patientforename;
	protected Integer wardid;
	protected String ward;
	protected Integer containerquantity;
	protected String adultcontainer;
	protected Integer collectionstatus;
	protected String collector;
	protected ims.framework.utils.DateTime collectiondatetime;
	protected String collectioncomments;
	protected Integer collectingmos;
	protected Integer specimencontainerid;
	protected String paediatriccontainer;
	protected Integer paediatriccontainerid;
	protected Float adultvolume;
	protected Float paediatricvolume;
	protected Integer dftnooflabelsets;
	protected Float containeradultvolume;
	protected Float containerpaediatricvolume;
	protected Integer orderspecimenid;
	protected String placerordnum;
	protected Integer orderinvestigationid;
	private boolean isValidated = false;
	private boolean isBusy = false;
}
