/** * Update the ValueObject with the Domain Object. * * @param map DomainObjectMap of DomainObjects to already created ValueObjects. * @param valueObject to be updated * @param domainObject ims.core.admin.domain.objects.Referral */ public static ims.core.vo.ReferralListVo insert( DomainObjectMap map, ims.core.vo.ReferralListVo valueObject, ims.core.admin.domain.objects.Referral domainObject) { if (null == domainObject) { return valueObject; } if (null == map) { map = new DomainObjectMap(); } valueObject.setID_Referral(domainObject.getId()); valueObject.setIsRIE(domainObject.getIsRIE()); // If this is a recordedInError record, and the domainObject // value isIncludeRecord has not been set, then we return null and // not the value object if (valueObject.getIsRIE() != null && valueObject.getIsRIE().booleanValue() == true && !domainObject.isIncludeRecord()) return null; // If this is not a recordedInError record, and the domainObject // value isIncludeRecord has been set, then we return null and // not the value object if ((valueObject.getIsRIE() == null || valueObject.getIsRIE().booleanValue() == false) && domainObject.isIncludeRecord()) return null; // AuthoringDateTime java.util.Date AuthoringDateTime = domainObject.getAuthoringDateTime(); if (null != AuthoringDateTime) { valueObject.setAuthoringDateTime(new ims.framework.utils.DateTime(AuthoringDateTime)); } // ReferralReceivedDate java.util.Date ReferralReceivedDate = domainObject.getReferralReceivedDate(); if (null != ReferralReceivedDate) { valueObject.setReferralReceivedDate(new ims.framework.utils.Date(ReferralReceivedDate)); } // OriginalReferralDate java.util.Date OriginalReferralDate = domainObject.getOriginalReferralDate(); if (null != OriginalReferralDate) { valueObject.setOriginalReferralDate(new ims.framework.utils.Date(OriginalReferralDate)); } return valueObject; }