コード例 #1
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as MedicinalProductIndication;

            if (dest == null)
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }

            base.CopyTo(dest);
            if (Subject != null)
            {
                dest.Subject = new List <Hl7.Fhir.Model.ResourceReference>(Subject.DeepCopy());
            }
            if (DiseaseSymptomProcedure != null)
            {
                dest.DiseaseSymptomProcedure = (Hl7.Fhir.Model.CodeableConcept)DiseaseSymptomProcedure.DeepCopy();
            }
            if (DiseaseStatus != null)
            {
                dest.DiseaseStatus = (Hl7.Fhir.Model.CodeableConcept)DiseaseStatus.DeepCopy();
            }
            if (Comorbidity != null)
            {
                dest.Comorbidity = new List <Hl7.Fhir.Model.CodeableConcept>(Comorbidity.DeepCopy());
            }
            if (IntendedEffect != null)
            {
                dest.IntendedEffect = (Hl7.Fhir.Model.CodeableConcept)IntendedEffect.DeepCopy();
            }
            if (Duration != null)
            {
                dest.Duration = (Hl7.Fhir.Model.Quantity)Duration.DeepCopy();
            }
            if (OtherTherapy != null)
            {
                dest.OtherTherapy = new List <Hl7.Fhir.Model.MedicinalProductIndication.OtherTherapyComponent>(OtherTherapy.DeepCopy());
            }
            if (UndesirableEffect != null)
            {
                dest.UndesirableEffect = new List <Hl7.Fhir.Model.ResourceReference>(UndesirableEffect.DeepCopy());
            }
            if (Population != null)
            {
                dest.Population = new List <Hl7.Fhir.Model.Population>(Population.DeepCopy());
            }
            return(dest);
        }
コード例 #2
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as MedicinalProductContraindication;

            if (dest == null)
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }

            base.CopyTo(dest);
            if (Subject != null)
            {
                dest.Subject = new List <Hl7.Fhir.Model.ResourceReference>(Subject.DeepCopy());
            }
            if (Disease != null)
            {
                dest.Disease = (Hl7.Fhir.Model.CodeableConcept)Disease.DeepCopy();
            }
            if (DiseaseStatus != null)
            {
                dest.DiseaseStatus = (Hl7.Fhir.Model.CodeableConcept)DiseaseStatus.DeepCopy();
            }
            if (Comorbidity != null)
            {
                dest.Comorbidity = new List <Hl7.Fhir.Model.CodeableConcept>(Comorbidity.DeepCopy());
            }
            if (TherapeuticIndication != null)
            {
                dest.TherapeuticIndication = new List <Hl7.Fhir.Model.ResourceReference>(TherapeuticIndication.DeepCopy());
            }
            if (OtherTherapy != null)
            {
                dest.OtherTherapy = new List <Hl7.Fhir.Model.MedicinalProductContraindication.OtherTherapyComponent>(OtherTherapy.DeepCopy());
            }
            if (Population != null)
            {
                dest.Population = new List <Hl7.Fhir.Model.Population>(Population.DeepCopy());
            }
            return(dest);
        }