Ejemplo n.º 1
0
        public CdaProcedure(POCD_MT000040Procedure pocdProcedure)
        {
            if (pocdProcedure.id != null)
            {
                if (pocdProcedure.id.Length > 0)
                {
                    this.Id = pocdProcedure.id[0].root;
                }
            }

            this.Code = CdaCode.FromPocd(pocdProcedure.code);

            this.EffectiveTime = CdaEffectiveTime.FromPocd(pocdProcedure.effectiveTime);
        }
        public CdaSimpleObservation(POCD_MT000040Observation pocdObs)
        {
            // *** Template Ids ***
            this.TemplateIds = new CdaTemplateIdList(pocdObs.templateId);

            // *** Observation Id ***
            if (pocdObs.id != null)
            {
                if (pocdObs.id.Length > 0)
                {
                    this.Id = pocdObs.id[0].root;
                }
            }

            // *** Code ***
            this.Code = CdaCode.FromPocd(pocdObs.code);

            // *** Negation ***
            if (pocdObs.negationIndSpecified)
            {
                this.NegationIndicator = pocdObs.negationInd;
            }

            // *** Status ***
            if (pocdObs.statusCode != null)
            {
                Hl7ProblemActStatus stat = Hl7ProblemActStatus.unknown;

                if (Enum.TryParse <Hl7ProblemActStatus>(pocdObs.statusCode.code, out stat))
                {
                    this.Status = stat;
                }
            }

            // *** Effective Time ***
            if (pocdObs.effectiveTime != null)
            {
                this.EffectiveTime = CdaEffectiveTime.FromPocd(pocdObs.effectiveTime);
            }

            this.Mood = x_ActMoodDocumentObservation.EVN;
        }