コード例 #1
0
ファイル: PlanOfCare.java プロジェクト: HobbesFNM/openMAXIMS
 public static void fillFieldsfromXML(
     org.dom4j.Element el,
     ims.domain.DomainFactory factory,
     PlanOfCare obj,
     java.util.HashMap domMap)
     throws Exception {
   org.dom4j.Element fldEl;
   fldEl = el.element("clinicalContact");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setClinicalContact(
         ims.core.admin.domain.objects.ClinicalContact.getClinicalContactfromXML(
             fldEl, factory, domMap));
   }
   fldEl = el.element("careContext");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setCareContext(
         ims.core.admin.domain.objects.CareContext.getCareContextfromXML(fldEl, factory, domMap));
   }
   fldEl = el.element("authoringInformation");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setAuthoringInformation(
         ims.core.clinical.domain.objects.AuthoringInformation.getAuthoringInformationfromXML(
             fldEl, factory, domMap));
   }
   fldEl = el.element("startDateTime");
   if (fldEl != null) {
     obj.setStartDateTime(
         new java.text.SimpleDateFormat("yyyyMMddHHmmssSSS").parse(fldEl.getTextTrim()));
   }
   fldEl = el.element("startHCP");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setStartHCP(
         ims.core.resource.people.domain.objects.Hcp.getHcpfromXML(fldEl, factory, domMap));
   }
   fldEl = el.element("levelOfIntervention");
   if (fldEl != null) {
     obj.setLevelOfIntervention(ims.framework.utils.Color.getColor(fldEl.getTextTrim()));
   }
   fldEl = el.element("group");
   if (fldEl != null) {
     fldEl = fldEl.element("lki");
     obj.setGroup(ims.domain.lookups.LookupInstance.fromXMLString(fldEl, factory));
   }
   fldEl = el.element("title");
   if (fldEl != null) {
     obj.setTitle(new String(fldEl.getTextTrim()));
   }
   fldEl = el.element("status");
   if (fldEl != null) {
     fldEl = fldEl.element("lki");
     obj.setStatus(ims.domain.lookups.LookupInstance.fromXMLString(fldEl, factory));
   }
   fldEl = el.element("resolvedDateTime");
   if (fldEl != null) {
     obj.setResolvedDateTime(
         new java.text.SimpleDateFormat("yyyyMMddHHmmssSSS").parse(fldEl.getTextTrim()));
   }
   fldEl = el.element("resolvingHCP");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setResolvingHCP(
         ims.core.resource.people.domain.objects.Hcp.getHcpfromXML(fldEl, factory, domMap));
   }
   fldEl = el.element("confirmingDateTime");
   if (fldEl != null) {
     obj.setConfirmingDateTime(
         new java.text.SimpleDateFormat("yyyyMMddHHmmssSSS").parse(fldEl.getTextTrim()));
   }
   fldEl = el.element("confirmingHCP");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setConfirmingHCP(
         ims.core.resource.people.domain.objects.Hcp.getHcpfromXML(fldEl, factory, domMap));
   }
   fldEl = el.element("actions");
   if (fldEl != null) {
     fldEl = fldEl.element("set");
     obj.setActions(
         ims.nursing.domain.objects.PlanOfCareActions.fromSetXMLString(
             fldEl, factory, obj.getActions(), domMap));
   }
   fldEl = el.element("assessmentQuestion");
   if (fldEl != null) {
     fldEl = fldEl.element("class");
     obj.setAssessmentQuestion(
         ims.assessment.configuration.domain.objects.AssessmentQuestion
             .getAssessmentQuestionfromXML(fldEl, factory, domMap));
   }
   fldEl = el.element("answerHistory");
   if (fldEl != null) {
     fldEl = fldEl.element("set");
     obj.setAnswerHistory(
         ims.nursing.domain.objects.PlanOfCareHistory.fromSetXMLString(
             fldEl, factory, obj.getAnswerHistory(), domMap));
   }
 }