public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Account;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (StatusElement != null)
            {
                dest.StatusElement = (Code <Hl7.Fhir.Model.Account.AccountStatus>)StatusElement.DeepCopy();
            }
            if (Type != null)
            {
                dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
            }
            if (NameElement != null)
            {
                dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
            }
            if (Subject != null)
            {
                dest.Subject = (Hl7.Fhir.Model.ResourceReference)Subject.DeepCopy();
            }
            if (Period != null)
            {
                dest.Period = (Hl7.Fhir.Model.Period)Period.DeepCopy();
            }
            if (Active != null)
            {
                dest.Active = (Hl7.Fhir.Model.Period)Active.DeepCopy();
            }
            if (Balance != null)
            {
                dest.Balance = (Hl7.Fhir.Model.Money)Balance.DeepCopy();
            }
            if (Coverage != null)
            {
                dest.Coverage = new List <Hl7.Fhir.Model.Account.CoverageComponent>(Coverage.DeepCopy());
            }
            if (Owner != null)
            {
                dest.Owner = (Hl7.Fhir.Model.ResourceReference)Owner.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Guarantor != null)
            {
                dest.Guarantor = new List <Hl7.Fhir.Model.Account.GuarantorComponent>(Guarantor.DeepCopy());
            }
            return(dest);
        }
Exemple #2
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Substance;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Type != null)
                {
                    dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (Instance != null)
                {
                    dest.Instance = (Hl7.Fhir.Model.Substance.SubstanceInstanceComponent)Instance.DeepCopy();
                }
                if (Ingredient != null)
                {
                    dest.Ingredient = new List <Hl7.Fhir.Model.Substance.SubstanceIngredientComponent>(Ingredient.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #3
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as ProtocolComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (DoseSequenceElement != null)
                    {
                        dest.DoseSequenceElement = (Hl7.Fhir.Model.Integer)DoseSequenceElement.DeepCopy();
                    }
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (Authority != null)
                    {
                        dest.Authority = (Hl7.Fhir.Model.ResourceReference)Authority.DeepCopy();
                    }
                    if (SeriesElement != null)
                    {
                        dest.SeriesElement = (Hl7.Fhir.Model.FhirString)SeriesElement.DeepCopy();
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
Exemple #4
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as DocumentManifest;

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

            base.CopyTo(dest);
            if (MasterIdentifier != null)
            {
                dest.MasterIdentifier = (Hl7.Fhir.Model.Identifier)MasterIdentifier.DeepCopy();
            }
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (StatusElement != null)
            {
                dest.StatusElement = (Code <Hl7.Fhir.Model.DocumentReferenceStatus>)StatusElement.DeepCopy();
            }
            if (Type != null)
            {
                dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
            }
            if (Subject != null)
            {
                dest.Subject = (Hl7.Fhir.Model.ResourceReference)Subject.DeepCopy();
            }
            if (CreatedElement != null)
            {
                dest.CreatedElement = (Hl7.Fhir.Model.FhirDateTime)CreatedElement.DeepCopy();
            }
            if (Author != null)
            {
                dest.Author = new List <Hl7.Fhir.Model.ResourceReference>(Author.DeepCopy());
            }
            if (Recipient != null)
            {
                dest.Recipient = new List <Hl7.Fhir.Model.ResourceReference>(Recipient.DeepCopy());
            }
            if (SourceElement != null)
            {
                dest.SourceElement = (Hl7.Fhir.Model.FhirUri)SourceElement.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Content != null)
            {
                dest.Content = new List <Hl7.Fhir.Model.ResourceReference>(Content.DeepCopy());
            }
            if (Related != null)
            {
                dest.Related = new List <Hl7.Fhir.Model.DocumentManifest.RelatedComponent>(Related.DeepCopy());
            }
            return(dest);
        }
Exemple #5
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as TreatmentComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (Procedure != null)
                    {
                        dest.Procedure = (Hl7.Fhir.Model.CodeableConcept)Procedure.DeepCopy();
                    }
                    if (Additive != null)
                    {
                        dest.Additive = new List <Hl7.Fhir.Model.ResourceReference>(Additive.DeepCopy());
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
Exemple #6
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Location;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (StatusElement != null)
            {
                dest.StatusElement = (Code <Hl7.Fhir.Model.Location.LocationStatus>)StatusElement.DeepCopy();
            }
            if (NameElement != null)
            {
                dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (ModeElement != null)
            {
                dest.ModeElement = (Code <Hl7.Fhir.Model.Location.LocationMode>)ModeElement.DeepCopy();
            }
            if (Type != null)
            {
                dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
            }
            if (Telecom != null)
            {
                dest.Telecom = new List <Hl7.Fhir.Model.ContactPoint>(Telecom.DeepCopy());
            }
            if (Address != null)
            {
                dest.Address = (Hl7.Fhir.Model.Address)Address.DeepCopy();
            }
            if (PhysicalType != null)
            {
                dest.PhysicalType = (Hl7.Fhir.Model.CodeableConcept)PhysicalType.DeepCopy();
            }
            if (Position != null)
            {
                dest.Position = (Hl7.Fhir.Model.Location.PositionComponent)Position.DeepCopy();
            }
            if (ManagingOrganization != null)
            {
                dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
            }
            if (PartOf != null)
            {
                dest.PartOf = (Hl7.Fhir.Model.ResourceReference)PartOf.DeepCopy();
            }
            return(dest);
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Appointment;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (StatusElement != null)
            {
                dest.StatusElement = (Code <Hl7.Fhir.Model.Appointment.AppointmentStatus>)StatusElement.DeepCopy();
            }
            if (Type != null)
            {
                dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
            }
            if (Reason != null)
            {
                dest.Reason = (Hl7.Fhir.Model.CodeableConcept)Reason.DeepCopy();
            }
            if (PriorityElement != null)
            {
                dest.PriorityElement = (Hl7.Fhir.Model.UnsignedInt)PriorityElement.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (StartElement != null)
            {
                dest.StartElement = (Hl7.Fhir.Model.Instant)StartElement.DeepCopy();
            }
            if (EndElement != null)
            {
                dest.EndElement = (Hl7.Fhir.Model.Instant)EndElement.DeepCopy();
            }
            if (MinutesDurationElement != null)
            {
                dest.MinutesDurationElement = (Hl7.Fhir.Model.PositiveInt)MinutesDurationElement.DeepCopy();
            }
            if (Slot != null)
            {
                dest.Slot = new List <Hl7.Fhir.Model.ResourceReference>(Slot.DeepCopy());
            }
            if (CommentElement != null)
            {
                dest.CommentElement = (Hl7.Fhir.Model.FhirString)CommentElement.DeepCopy();
            }
            if (Participant != null)
            {
                dest.Participant = new List <Hl7.Fhir.Model.Appointment.ParticipantComponent>(Participant.DeepCopy());
            }
            return(dest);
        }
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as RecommendationComponent;

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

                base.CopyTo(dest);
                if (VaccineCode != null)
                {
                    dest.VaccineCode = new List <Hl7.Fhir.Model.CodeableConcept>(VaccineCode.DeepCopy());
                }
                if (TargetDisease != null)
                {
                    dest.TargetDisease = new List <Hl7.Fhir.Model.CodeableConcept>(TargetDisease.DeepCopy());
                }
                if (ContraindicatedVaccineCode != null)
                {
                    dest.ContraindicatedVaccineCode = new List <Hl7.Fhir.Model.CodeableConcept>(ContraindicatedVaccineCode.DeepCopy());
                }
                if (ForecastStatus != null)
                {
                    dest.ForecastStatus = (Hl7.Fhir.Model.CodeableConcept)ForecastStatus.DeepCopy();
                }
                if (ForecastReason != null)
                {
                    dest.ForecastReason = new List <Hl7.Fhir.Model.CodeableConcept>(ForecastReason.DeepCopy());
                }
                if (DateCriterion != null)
                {
                    dest.DateCriterion = new List <Hl7.Fhir.Model.ImmunizationRecommendation.DateCriterionComponent>(DateCriterion.DeepCopy());
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (SeriesElement != null)
                {
                    dest.SeriesElement = (Hl7.Fhir.Model.FhirString)SeriesElement.DeepCopy();
                }
                if (DoseNumberElement != null)
                {
                    dest.DoseNumberElement = (Hl7.Fhir.Model.FhirString)DoseNumberElement.DeepCopy();
                }
                if (SeriesDosesElement != null)
                {
                    dest.SeriesDosesElement = (Hl7.Fhir.Model.FhirString)SeriesDosesElement.DeepCopy();
                }
                if (SupportingImmunization != null)
                {
                    dest.SupportingImmunization = new List <Hl7.Fhir.Model.ResourceReference>(SupportingImmunization.DeepCopy());
                }
                if (SupportingPatientInformation != null)
                {
                    dest.SupportingPatientInformation = new List <Hl7.Fhir.Model.ResourceReference>(SupportingPatientInformation.DeepCopy());
                }
                return(dest);
            }
Exemple #9
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Expression;

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

            base.CopyTo(dest);
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (NameElement != null)
            {
                dest.NameElement = (Hl7.Fhir.Model.Id)NameElement.DeepCopy();
            }
            if (LanguageElement != null)
            {
                dest.LanguageElement = (Hl7.Fhir.Model.Code)LanguageElement.DeepCopy();
            }
            if (ExpressionElement != null)
            {
                dest.ExpressionElement = (Hl7.Fhir.Model.FhirString)ExpressionElement.DeepCopy();
            }
            if (ReferenceElement != null)
            {
                dest.ReferenceElement = (Hl7.Fhir.Model.FhirUri)ReferenceElement.DeepCopy();
            }
            return(dest);
        }
Exemple #10
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as CarePlanGoalComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (StatusElement != null)
                    {
                        dest.StatusElement = (Code <Hl7.Fhir.Model.CarePlan.CarePlanGoalStatus>)StatusElement.DeepCopy();
                    }
                    if (NotesElement != null)
                    {
                        dest.NotesElement = (Hl7.Fhir.Model.FhirString)NotesElement.DeepCopy();
                    }
                    if (Concern != null)
                    {
                        dest.Concern = new List <Hl7.Fhir.Model.ResourceReference>(Concern.DeepCopy());
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Goal;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Patient != null)
                {
                    dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
                }
                if (TargetDateElement != null)
                {
                    dest.TargetDateElement = (Hl7.Fhir.Model.Date)TargetDateElement.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.Goal.GoalStatus>)StatusElement.DeepCopy();
                }
                if (StatusDateElement != null)
                {
                    dest.StatusDateElement = (Hl7.Fhir.Model.Date)StatusDateElement.DeepCopy();
                }
                if (Author != null)
                {
                    dest.Author = (Hl7.Fhir.Model.ResourceReference)Author.DeepCopy();
                }
                if (Priority != null)
                {
                    dest.Priority = (Hl7.Fhir.Model.CodeableConcept)Priority.DeepCopy();
                }
                if (Concern != null)
                {
                    dest.Concern = new List <Hl7.Fhir.Model.ResourceReference>(Concern.DeepCopy());
                }
                if (NotesElement != null)
                {
                    dest.NotesElement = (Hl7.Fhir.Model.FhirString)NotesElement.DeepCopy();
                }
                if (Outcome != null)
                {
                    dest.Outcome = new List <Hl7.Fhir.Model.Goal.GoalOutcomeComponent>(Outcome.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #12
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as AllergyIntoleranceEventComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (Substance != null)
                    {
                        dest.Substance = (Hl7.Fhir.Model.CodeableConcept)Substance.DeepCopy();
                    }
                    if (CertaintyElement != null)
                    {
                        dest.CertaintyElement = (Code <Hl7.Fhir.Model.AllergyIntolerance.AllergyIntoleranceCertainty>)CertaintyElement.DeepCopy();
                    }
                    if (Manifestation != null)
                    {
                        dest.Manifestation = new List <Hl7.Fhir.Model.CodeableConcept>(Manifestation.DeepCopy());
                    }
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (OnsetElement != null)
                    {
                        dest.OnsetElement = (Hl7.Fhir.Model.FhirDateTime)OnsetElement.DeepCopy();
                    }
                    if (Duration != null)
                    {
                        dest.Duration = (Hl7.Fhir.Model.Duration)Duration.DeepCopy();
                    }
                    if (SeverityElement != null)
                    {
                        dest.SeverityElement = (Code <Hl7.Fhir.Model.AllergyIntolerance.AllergyIntoleranceSeverity>)SeverityElement.DeepCopy();
                    }
                    if (ExposureRoute != null)
                    {
                        dest.ExposureRoute = (Hl7.Fhir.Model.CodeableConcept)ExposureRoute.DeepCopy();
                    }
                    if (CommentElement != null)
                    {
                        dest.CommentElement = (Hl7.Fhir.Model.FhirString)CommentElement.DeepCopy();
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
Exemple #13
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as MedicinalProductPackaged;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (Subject != null)
            {
                dest.Subject = new List <Hl7.Fhir.Model.ResourceReference>(Subject.DeepCopy());
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (LegalStatusOfSupply != null)
            {
                dest.LegalStatusOfSupply = (Hl7.Fhir.Model.CodeableConcept)LegalStatusOfSupply.DeepCopy();
            }
            if (MarketingStatus != null)
            {
                dest.MarketingStatus = new List <Hl7.Fhir.Model.MarketingStatus>(MarketingStatus.DeepCopy());
            }
            if (MarketingAuthorization != null)
            {
                dest.MarketingAuthorization = (Hl7.Fhir.Model.ResourceReference)MarketingAuthorization.DeepCopy();
            }
            if (Manufacturer != null)
            {
                dest.Manufacturer = new List <Hl7.Fhir.Model.ResourceReference>(Manufacturer.DeepCopy());
            }
            if (BatchIdentifier != null)
            {
                dest.BatchIdentifier = new List <Hl7.Fhir.Model.MedicinalProductPackaged.BatchIdentifierComponent>(BatchIdentifier.DeepCopy());
            }
            if (PackageItem != null)
            {
                dest.PackageItem = new List <Hl7.Fhir.Model.MedicinalProductPackaged.PackageItemComponent>(PackageItem.DeepCopy());
            }
            return(dest);
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as OrderResponse;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Request != null)
                {
                    dest.Request = (Hl7.Fhir.Model.ResourceReference)Request.DeepCopy();
                }
                if (DateElement != null)
                {
                    dest.DateElement = (Hl7.Fhir.Model.FhirDateTime)DateElement.DeepCopy();
                }
                if (Who != null)
                {
                    dest.Who = (Hl7.Fhir.Model.ResourceReference)Who.DeepCopy();
                }
                if (Authority != null)
                {
                    dest.Authority = (Hl7.Fhir.Model.Element)Authority.DeepCopy();
                }
                if (OrderStatus_Element != null)
                {
                    dest.OrderStatus_Element = (Code <Hl7.Fhir.Model.OrderResponse.OrderStatus>)OrderStatus_Element.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (Fulfillment != null)
                {
                    dest.Fulfillment = new List <Hl7.Fhir.Model.ResourceReference>(Fulfillment.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #15
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as VaccinationProtocolComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (DoseSequenceElement != null)
                    {
                        dest.DoseSequenceElement = (Hl7.Fhir.Model.PositiveInt)DoseSequenceElement.DeepCopy();
                    }
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (Authority != null)
                    {
                        dest.Authority = (Hl7.Fhir.Model.ResourceReference)Authority.DeepCopy();
                    }
                    if (SeriesElement != null)
                    {
                        dest.SeriesElement = (Hl7.Fhir.Model.FhirString)SeriesElement.DeepCopy();
                    }
                    if (SeriesDosesElement != null)
                    {
                        dest.SeriesDosesElement = (Hl7.Fhir.Model.PositiveInt)SeriesDosesElement.DeepCopy();
                    }
                    if (TargetDisease != null)
                    {
                        dest.TargetDisease = new List <Hl7.Fhir.Model.CodeableConcept>(TargetDisease.DeepCopy());
                    }
                    if (DoseStatus != null)
                    {
                        dest.DoseStatus = (Hl7.Fhir.Model.CodeableConcept)DoseStatus.DeepCopy();
                    }
                    if (DoseStatusReason != null)
                    {
                        dest.DoseStatusReason = (Hl7.Fhir.Model.CodeableConcept)DoseStatusReason.DeepCopy();
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as BodyStructure;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (ActiveElement != null)
            {
                dest.ActiveElement = (Hl7.Fhir.Model.FhirBoolean)ActiveElement.DeepCopy();
            }
            if (Morphology != null)
            {
                dest.Morphology = (Hl7.Fhir.Model.CodeableConcept)Morphology.DeepCopy();
            }
            if (Location != null)
            {
                dest.Location = (Hl7.Fhir.Model.CodeableConcept)Location.DeepCopy();
            }
            if (LocationQualifier != null)
            {
                dest.LocationQualifier = new List <Hl7.Fhir.Model.CodeableConcept>(LocationQualifier.DeepCopy());
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Image != null)
            {
                dest.Image = new List <Hl7.Fhir.Model.Attachment>(Image.DeepCopy());
            }
            if (Patient != null)
            {
                dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
            }
            return(dest);
        }
Exemple #17
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as ImagingObjectSelection;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (UidElement != null)
                {
                    dest.UidElement = (Hl7.Fhir.Model.Oid)UidElement.DeepCopy();
                }
                if (Patient != null)
                {
                    dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
                }
                if (Title != null)
                {
                    dest.Title = (Hl7.Fhir.Model.CodeableConcept)Title.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (Author != null)
                {
                    dest.Author = (Hl7.Fhir.Model.ResourceReference)Author.DeepCopy();
                }
                if (AuthoringTimeElement != null)
                {
                    dest.AuthoringTimeElement = (Hl7.Fhir.Model.FhirDateTime)AuthoringTimeElement.DeepCopy();
                }
                if (Study != null)
                {
                    dest.Study = new List <Hl7.Fhir.Model.ImagingObjectSelection.StudyComponent>(Study.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as NotAvailableComponent;

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

                base.CopyTo(dest);
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (During != null)
                {
                    dest.During = (Hl7.Fhir.Model.Period)During.DeepCopy();
                }
                return(dest);
            }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Substance;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
            }
            if (StatusElement != null)
            {
                dest.StatusElement = (Code <Hl7.Fhir.Model.Substance.FHIRSubstanceStatus>)StatusElement.DeepCopy();
            }
            if (Category != null)
            {
                dest.Category = new List <Hl7.Fhir.Model.CodeableConcept>(Category.DeepCopy());
            }
            if (Code != null)
            {
                dest.Code = (Hl7.Fhir.Model.CodeableConcept)Code.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Instance != null)
            {
                dest.Instance = new List <Hl7.Fhir.Model.Substance.InstanceComponent>(Instance.DeepCopy());
            }
            if (Ingredient != null)
            {
                dest.Ingredient = new List <Hl7.Fhir.Model.Substance.IngredientComponent>(Ingredient.DeepCopy());
            }
            return(dest);
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as MedicinalProductInteraction;

            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 (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Interactant != null)
            {
                dest.Interactant = new List <Hl7.Fhir.Model.MedicinalProductInteraction.InteractantComponent>(Interactant.DeepCopy());
            }
            if (Type != null)
            {
                dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
            }
            if (Effect != null)
            {
                dest.Effect = (Hl7.Fhir.Model.CodeableConcept)Effect.DeepCopy();
            }
            if (Incidence != null)
            {
                dest.Incidence = (Hl7.Fhir.Model.CodeableConcept)Incidence.DeepCopy();
            }
            if (Management != null)
            {
                dest.Management = (Hl7.Fhir.Model.CodeableConcept)Management.DeepCopy();
            }
            return(dest);
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as BodySite;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Patient != null)
                {
                    dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
                }
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Code != null)
                {
                    dest.Code = (Hl7.Fhir.Model.CodeableConcept)Code.DeepCopy();
                }
                if (Modifier != null)
                {
                    dest.Modifier = new List <Hl7.Fhir.Model.CodeableConcept>(Modifier.DeepCopy());
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (Image != null)
                {
                    dest.Image = new List <Hl7.Fhir.Model.Attachment>(Image.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #22
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as ContainerComponent;

                if (dest != null)
                {
                    base.CopyTo(dest);
                    if (Identifier != null)
                    {
                        dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                    }
                    if (DescriptionElement != null)
                    {
                        dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                    }
                    if (Type != null)
                    {
                        dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
                    }
                    if (Capacity != null)
                    {
                        dest.Capacity = (Hl7.Fhir.Model.SimpleQuantity)Capacity.DeepCopy();
                    }
                    if (SpecimenQuantity != null)
                    {
                        dest.SpecimenQuantity = (Hl7.Fhir.Model.SimpleQuantity)SpecimenQuantity.DeepCopy();
                    }
                    if (Additive != null)
                    {
                        dest.Additive = (Hl7.Fhir.Model.Element)Additive.DeepCopy();
                    }
                    return(dest);
                }
                else
                {
                    throw new ArgumentException("Can only copy to an object of the same type", "other");
                }
            }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as OrderedDistribution;

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

            base.CopyTo(dest);
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Note != null)
            {
                dest.Note = new List <Hl7.Fhir.Model.Annotation>(Note.DeepCopy());
            }
            if (NumberOfIntervalsElement != null)
            {
                dest.NumberOfIntervalsElement = (Hl7.Fhir.Model.Integer)NumberOfIntervalsElement.DeepCopy();
            }
            if (BottomOfFirstInterval != null)
            {
                dest.BottomOfFirstInterval = (Hl7.Fhir.Model.Quantity)BottomOfFirstInterval.DeepCopy();
            }
            if (Interval != null)
            {
                dest.Interval = new List <Hl7.Fhir.Model.OrderedDistribution.IntervalComponent>(Interval.DeepCopy());
            }
            if (TopOfInterval != null)
            {
                dest.TopOfInterval = (Hl7.Fhir.Model.Quantity)TopOfInterval.DeepCopy();
            }
            return(dest);
        }
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as ArmComponent;

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

                base.CopyTo(dest);
                if (NameElement != null)
                {
                    dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
                }
                if (Code != null)
                {
                    dest.Code = (Hl7.Fhir.Model.CodeableConcept)Code.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                return(dest);
            }
Exemple #25
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as ImagingManifest;

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

            base.CopyTo(dest);
            if (Identifier != null)
            {
                dest.Identifier = (Hl7.Fhir.Model.Identifier)Identifier.DeepCopy();
            }
            if (Patient != null)
            {
                dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
            }
            if (AuthoringTimeElement != null)
            {
                dest.AuthoringTimeElement = (Hl7.Fhir.Model.FhirDateTime)AuthoringTimeElement.DeepCopy();
            }
            if (Author != null)
            {
                dest.Author = (Hl7.Fhir.Model.ResourceReference)Author.DeepCopy();
            }
            if (DescriptionElement != null)
            {
                dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
            }
            if (Study != null)
            {
                dest.Study = new List <Hl7.Fhir.Model.ImagingManifest.StudyComponent>(Study.DeepCopy());
            }
            return(dest);
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as ReferralRequest;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.ReferralRequest.ReferralStatus>)StatusElement.DeepCopy();
                }
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (DateElement != null)
                {
                    dest.DateElement = (Hl7.Fhir.Model.FhirDateTime)DateElement.DeepCopy();
                }
                if (Type != null)
                {
                    dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
                }
                if (Specialty != null)
                {
                    dest.Specialty = (Hl7.Fhir.Model.CodeableConcept)Specialty.DeepCopy();
                }
                if (Priority != null)
                {
                    dest.Priority = (Hl7.Fhir.Model.CodeableConcept)Priority.DeepCopy();
                }
                if (Patient != null)
                {
                    dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
                }
                if (Requester != null)
                {
                    dest.Requester = (Hl7.Fhir.Model.ResourceReference)Requester.DeepCopy();
                }
                if (Recipient != null)
                {
                    dest.Recipient = new List <Hl7.Fhir.Model.ResourceReference>(Recipient.DeepCopy());
                }
                if (Encounter != null)
                {
                    dest.Encounter = (Hl7.Fhir.Model.ResourceReference)Encounter.DeepCopy();
                }
                if (DateSentElement != null)
                {
                    dest.DateSentElement = (Hl7.Fhir.Model.FhirDateTime)DateSentElement.DeepCopy();
                }
                if (Reason != null)
                {
                    dest.Reason = (Hl7.Fhir.Model.CodeableConcept)Reason.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (ServiceRequested != null)
                {
                    dest.ServiceRequested = new List <Hl7.Fhir.Model.CodeableConcept>(ServiceRequested.DeepCopy());
                }
                if (SupportingInformation != null)
                {
                    dest.SupportingInformation = new List <Hl7.Fhir.Model.ResourceReference>(SupportingInformation.DeepCopy());
                }
                if (FulfillmentTime != null)
                {
                    dest.FulfillmentTime = (Hl7.Fhir.Model.Period)FulfillmentTime.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #27
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as NamingSystem;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (NameElement != null)
                {
                    dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
                }
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.ConformanceResourceStatus>)StatusElement.DeepCopy();
                }
                if (KindElement != null)
                {
                    dest.KindElement = (Code <Hl7.Fhir.Model.NamingSystem.NamingSystemType>)KindElement.DeepCopy();
                }
                if (PublisherElement != null)
                {
                    dest.PublisherElement = (Hl7.Fhir.Model.FhirString)PublisherElement.DeepCopy();
                }
                if (Contact != null)
                {
                    dest.Contact = new List <Hl7.Fhir.Model.NamingSystem.ContactComponent>(Contact.DeepCopy());
                }
                if (ResponsibleElement != null)
                {
                    dest.ResponsibleElement = (Hl7.Fhir.Model.FhirString)ResponsibleElement.DeepCopy();
                }
                if (DateElement != null)
                {
                    dest.DateElement = (Hl7.Fhir.Model.FhirDateTime)DateElement.DeepCopy();
                }
                if (Type != null)
                {
                    dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (UseContext != null)
                {
                    dest.UseContext = new List <Hl7.Fhir.Model.CodeableConcept>(UseContext.DeepCopy());
                }
                if (UsageElement != null)
                {
                    dest.UsageElement = (Hl7.Fhir.Model.FhirString)UsageElement.DeepCopy();
                }
                if (UniqueId != null)
                {
                    dest.UniqueId = new List <Hl7.Fhir.Model.NamingSystem.UniqueIdComponent>(UniqueId.DeepCopy());
                }
                if (ReplacedBy != null)
                {
                    dest.ReplacedBy = (Hl7.Fhir.Model.ResourceReference)ReplacedBy.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as SearchParameter;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (UrlElement != null)
                {
                    dest.UrlElement = (Hl7.Fhir.Model.FhirUri)UrlElement.DeepCopy();
                }
                if (NameElement != null)
                {
                    dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
                }
                if (PublisherElement != null)
                {
                    dest.PublisherElement = (Hl7.Fhir.Model.FhirString)PublisherElement.DeepCopy();
                }
                if (Contact != null)
                {
                    dest.Contact = new List <Hl7.Fhir.Model.SearchParameter.SearchParameterContactComponent>(Contact.DeepCopy());
                }
                if (RequirementsElement != null)
                {
                    dest.RequirementsElement = (Hl7.Fhir.Model.FhirString)RequirementsElement.DeepCopy();
                }
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.ConformanceResourceStatus>)StatusElement.DeepCopy();
                }
                if (ExperimentalElement != null)
                {
                    dest.ExperimentalElement = (Hl7.Fhir.Model.FhirBoolean)ExperimentalElement.DeepCopy();
                }
                if (DateElement != null)
                {
                    dest.DateElement = (Hl7.Fhir.Model.FhirDateTime)DateElement.DeepCopy();
                }
                if (BaseElement != null)
                {
                    dest.BaseElement = (Hl7.Fhir.Model.Code)BaseElement.DeepCopy();
                }
                if (TypeElement != null)
                {
                    dest.TypeElement = (Hl7.Fhir.Model.Code)TypeElement.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (XpathElement != null)
                {
                    dest.XpathElement = (Hl7.Fhir.Model.FhirString)XpathElement.DeepCopy();
                }
                if (TargetElement != null)
                {
                    dest.TargetElement = new List <Hl7.Fhir.Model.Code>(TargetElement.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Exemple #29
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as ClinicalImpression;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Patient != null)
                {
                    dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
                }
                if (Assessor != null)
                {
                    dest.Assessor = (Hl7.Fhir.Model.ResourceReference)Assessor.DeepCopy();
                }
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.ClinicalImpression.ClinicalImpressionStatus>)StatusElement.DeepCopy();
                }
                if (DateElement != null)
                {
                    dest.DateElement = (Hl7.Fhir.Model.FhirDateTime)DateElement.DeepCopy();
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (Previous != null)
                {
                    dest.Previous = (Hl7.Fhir.Model.ResourceReference)Previous.DeepCopy();
                }
                if (Problem != null)
                {
                    dest.Problem = new List <Hl7.Fhir.Model.ResourceReference>(Problem.DeepCopy());
                }
                if (Trigger != null)
                {
                    dest.Trigger = (Hl7.Fhir.Model.Element)Trigger.DeepCopy();
                }
                if (Investigations != null)
                {
                    dest.Investigations = new List <Hl7.Fhir.Model.ClinicalImpression.InvestigationsComponent>(Investigations.DeepCopy());
                }
                if (ProtocolElement != null)
                {
                    dest.ProtocolElement = (Hl7.Fhir.Model.FhirUri)ProtocolElement.DeepCopy();
                }
                if (SummaryElement != null)
                {
                    dest.SummaryElement = (Hl7.Fhir.Model.FhirString)SummaryElement.DeepCopy();
                }
                if (Finding != null)
                {
                    dest.Finding = new List <Hl7.Fhir.Model.ClinicalImpression.FindingComponent>(Finding.DeepCopy());
                }
                if (Resolved != null)
                {
                    dest.Resolved = new List <Hl7.Fhir.Model.CodeableConcept>(Resolved.DeepCopy());
                }
                if (RuledOut != null)
                {
                    dest.RuledOut = new List <Hl7.Fhir.Model.ClinicalImpression.RuledOutComponent>(RuledOut.DeepCopy());
                }
                if (PrognosisElement != null)
                {
                    dest.PrognosisElement = (Hl7.Fhir.Model.FhirString)PrognosisElement.DeepCopy();
                }
                if (Plan != null)
                {
                    dest.Plan = new List <Hl7.Fhir.Model.ResourceReference>(Plan.DeepCopy());
                }
                if (Action != null)
                {
                    dest.Action = new List <Hl7.Fhir.Model.ResourceReference>(Action.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as DocumentReference;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (MasterIdentifier != null)
                {
                    dest.MasterIdentifier = (Hl7.Fhir.Model.Identifier)MasterIdentifier.DeepCopy();
                }
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Subject != null)
                {
                    dest.Subject = (Hl7.Fhir.Model.ResourceReference)Subject.DeepCopy();
                }
                if (Type != null)
                {
                    dest.Type = (Hl7.Fhir.Model.CodeableConcept)Type.DeepCopy();
                }
                if (Class != null)
                {
                    dest.Class = (Hl7.Fhir.Model.CodeableConcept)Class.DeepCopy();
                }
                if (Author != null)
                {
                    dest.Author = new List <Hl7.Fhir.Model.ResourceReference>(Author.DeepCopy());
                }
                if (Custodian != null)
                {
                    dest.Custodian = (Hl7.Fhir.Model.ResourceReference)Custodian.DeepCopy();
                }
                if (Authenticator != null)
                {
                    dest.Authenticator = (Hl7.Fhir.Model.ResourceReference)Authenticator.DeepCopy();
                }
                if (CreatedElement != null)
                {
                    dest.CreatedElement = (Hl7.Fhir.Model.FhirDateTime)CreatedElement.DeepCopy();
                }
                if (IndexedElement != null)
                {
                    dest.IndexedElement = (Hl7.Fhir.Model.Instant)IndexedElement.DeepCopy();
                }
                if (StatusElement != null)
                {
                    dest.StatusElement = (Code <Hl7.Fhir.Model.DocumentReferenceStatus>)StatusElement.DeepCopy();
                }
                if (DocStatus != null)
                {
                    dest.DocStatus = (Hl7.Fhir.Model.CodeableConcept)DocStatus.DeepCopy();
                }
                if (RelatesTo != null)
                {
                    dest.RelatesTo = new List <Hl7.Fhir.Model.DocumentReference.RelatesToComponent>(RelatesTo.DeepCopy());
                }
                if (DescriptionElement != null)
                {
                    dest.DescriptionElement = (Hl7.Fhir.Model.FhirString)DescriptionElement.DeepCopy();
                }
                if (SecurityLabel != null)
                {
                    dest.SecurityLabel = new List <Hl7.Fhir.Model.CodeableConcept>(SecurityLabel.DeepCopy());
                }
                if (Content != null)
                {
                    dest.Content = new List <Hl7.Fhir.Model.DocumentReference.ContentComponent>(Content.DeepCopy());
                }
                if (Context != null)
                {
                    dest.Context = (Hl7.Fhir.Model.DocumentReference.ContextComponent)Context.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }