Пример #1
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 EpisodeOfCare;

            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.EpisodeOfCare.EpisodeOfCareStatus>)StatusElement.DeepCopy();
            }
            if (StatusHistory != null)
            {
                dest.StatusHistory = new List <Hl7.Fhir.Model.EpisodeOfCare.StatusHistoryComponent>(StatusHistory.DeepCopy());
            }
            if (Type != null)
            {
                dest.Type = new List <Hl7.Fhir.Model.CodeableConcept>(Type.DeepCopy());
            }
            if (Diagnosis != null)
            {
                dest.Diagnosis = new List <Hl7.Fhir.Model.EpisodeOfCare.DiagnosisComponent>(Diagnosis.DeepCopy());
            }
            if (Patient != null)
            {
                dest.Patient = (Hl7.Fhir.Model.ResourceReference)Patient.DeepCopy();
            }
            if (ManagingOrganization != null)
            {
                dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
            }
            if (Period != null)
            {
                dest.Period = (Hl7.Fhir.Model.Period)Period.DeepCopy();
            }
            if (ReferralRequest != null)
            {
                dest.ReferralRequest = new List <Hl7.Fhir.Model.ResourceReference>(ReferralRequest.DeepCopy());
            }
            if (CareManager != null)
            {
                dest.CareManager = (Hl7.Fhir.Model.ResourceReference)CareManager.DeepCopy();
            }
            if (Team != null)
            {
                dest.Team = new List <Hl7.Fhir.Model.ResourceReference>(Team.DeepCopy());
            }
            if (Account != null)
            {
                dest.Account = new List <Hl7.Fhir.Model.ResourceReference>(Account.DeepCopy());
            }
            return(dest);
        }
Пример #3
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Endpoint;

            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.Endpoint.EndpointStatus>)StatusElement.DeepCopy();
            }
            if (ConnectionType != null)
            {
                dest.ConnectionType = (Hl7.Fhir.Model.Coding)ConnectionType.DeepCopy();
            }
            if (NameElement != null)
            {
                dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
            }
            if (ManagingOrganization != null)
            {
                dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
            }
            if (Contact != null)
            {
                dest.Contact = new List <Hl7.Fhir.Model.ContactPoint>(Contact.DeepCopy());
            }
            if (Period != null)
            {
                dest.Period = (Hl7.Fhir.Model.Period)Period.DeepCopy();
            }
            if (PayloadType != null)
            {
                dest.PayloadType = new List <Hl7.Fhir.Model.CodeableConcept>(PayloadType.DeepCopy());
            }
            if (PayloadMimeTypeElement != null)
            {
                dest.PayloadMimeTypeElement = new List <Hl7.Fhir.Model.Code>(PayloadMimeTypeElement.DeepCopy());
            }
            if (AddressElement != null)
            {
                dest.AddressElement = (Hl7.Fhir.Model.FhirUrl)AddressElement.DeepCopy();
            }
            if (HeaderElement != null)
            {
                dest.HeaderElement = new List <Hl7.Fhir.Model.FhirString>(HeaderElement.DeepCopy());
            }
            return(dest);
        }
Пример #4
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Person;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Name != null)
                {
                    dest.Name = new List <Hl7.Fhir.Model.HumanName>(Name.DeepCopy());
                }
                if (Telecom != null)
                {
                    dest.Telecom = new List <Hl7.Fhir.Model.ContactPoint>(Telecom.DeepCopy());
                }
                if (GenderElement != null)
                {
                    dest.GenderElement = (Code <Hl7.Fhir.Model.AdministrativeGender>)GenderElement.DeepCopy();
                }
                if (BirthDateElement != null)
                {
                    dest.BirthDateElement = (Hl7.Fhir.Model.Date)BirthDateElement.DeepCopy();
                }
                if (Address != null)
                {
                    dest.Address = new List <Hl7.Fhir.Model.Address>(Address.DeepCopy());
                }
                if (Photo != null)
                {
                    dest.Photo = (Hl7.Fhir.Model.Attachment)Photo.DeepCopy();
                }
                if (ManagingOrganization != null)
                {
                    dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
                }
                if (ActiveElement != null)
                {
                    dest.ActiveElement = (Hl7.Fhir.Model.FhirBoolean)ActiveElement.DeepCopy();
                }
                if (Link != null)
                {
                    dest.Link = new List <Hl7.Fhir.Model.Person.LinkComponent>(Link.DeepCopy());
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Пример #5
0
            public override IDeepCopyable CopyTo(IDeepCopyable other)
            {
                var dest = other as PractitionerRoleComponent;

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

                base.CopyTo(dest);
                if (ManagingOrganization != null)
                {
                    dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
                }
                if (Role != null)
                {
                    dest.Role = (Hl7.Fhir.Model.CodeableConcept)Role.DeepCopy();
                }
                if (Specialty != null)
                {
                    dest.Specialty = new List <Hl7.Fhir.Model.CodeableConcept>(Specialty.DeepCopy());
                }
                if (Period != null)
                {
                    dest.Period = (Hl7.Fhir.Model.Period)Period.DeepCopy();
                }
                if (Location != null)
                {
                    dest.Location = new List <Hl7.Fhir.Model.ResourceReference>(Location.DeepCopy());
                }
                if (HealthcareService != null)
                {
                    dest.HealthcareService = new List <Hl7.Fhir.Model.ResourceReference>(HealthcareService.DeepCopy());
                }
                return(dest);
            }
Пример #6
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Patient;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Identifier != null)
                {
                    dest.Identifier = new List <Hl7.Fhir.Model.Identifier>(Identifier.DeepCopy());
                }
                if (Name != null)
                {
                    dest.Name = new List <Hl7.Fhir.Model.HumanName>(Name.DeepCopy());
                }
                if (Telecom != null)
                {
                    dest.Telecom = new List <Hl7.Fhir.Model.Contact>(Telecom.DeepCopy());
                }
                if (Gender != null)
                {
                    dest.Gender = (Hl7.Fhir.Model.CodeableConcept)Gender.DeepCopy();
                }
                if (BirthDateElement != null)
                {
                    dest.BirthDateElement = (Hl7.Fhir.Model.FhirDateTime)BirthDateElement.DeepCopy();
                }
                if (Deceased != null)
                {
                    dest.Deceased = (Hl7.Fhir.Model.Element)Deceased.DeepCopy();
                }
                if (Address != null)
                {
                    dest.Address = new List <Hl7.Fhir.Model.Address>(Address.DeepCopy());
                }
                if (MaritalStatus != null)
                {
                    dest.MaritalStatus = (Hl7.Fhir.Model.CodeableConcept)MaritalStatus.DeepCopy();
                }
                if (MultipleBirth != null)
                {
                    dest.MultipleBirth = (Hl7.Fhir.Model.Element)MultipleBirth.DeepCopy();
                }
                if (Photo != null)
                {
                    dest.Photo = new List <Hl7.Fhir.Model.Attachment>(Photo.DeepCopy());
                }
                if (Contact != null)
                {
                    dest.Contact = new List <Hl7.Fhir.Model.Patient.ContactComponent>(Contact.DeepCopy());
                }
                if (Animal != null)
                {
                    dest.Animal = (Hl7.Fhir.Model.Patient.AnimalComponent)Animal.DeepCopy();
                }
                if (Communication != null)
                {
                    dest.Communication = new List <Hl7.Fhir.Model.CodeableConcept>(Communication.DeepCopy());
                }
                if (CareProvider != null)
                {
                    dest.CareProvider = new List <Hl7.Fhir.Model.ResourceReference>(CareProvider.DeepCopy());
                }
                if (ManagingOrganization != null)
                {
                    dest.ManagingOrganization = (Hl7.Fhir.Model.ResourceReference)ManagingOrganization.DeepCopy();
                }
                if (Link != null)
                {
                    dest.Link = new List <Hl7.Fhir.Model.Patient.PatientLinkComponent>(Link.DeepCopy());
                }
                if (ActiveElement != null)
                {
                    dest.ActiveElement = (Hl7.Fhir.Model.FhirBoolean)ActiveElement.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Пример #7
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as CareTeam;

            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.CareTeam.CareTeamStatus>)StatusElement.DeepCopy();
            }
            if (Category != null)
            {
                dest.Category = new List <Hl7.Fhir.Model.CodeableConcept>(Category.DeepCopy());
            }
            if (NameElement != null)
            {
                dest.NameElement = (Hl7.Fhir.Model.FhirString)NameElement.DeepCopy();
            }
            if (Subject != null)
            {
                dest.Subject = (Hl7.Fhir.Model.ResourceReference)Subject.DeepCopy();
            }
            if (Encounter != null)
            {
                dest.Encounter = (Hl7.Fhir.Model.ResourceReference)Encounter.DeepCopy();
            }
            if (Period != null)
            {
                dest.Period = (Hl7.Fhir.Model.Period)Period.DeepCopy();
            }
            if (Participant != null)
            {
                dest.Participant = new List <Hl7.Fhir.Model.CareTeam.ParticipantComponent>(Participant.DeepCopy());
            }
            if (ReasonCode != null)
            {
                dest.ReasonCode = new List <Hl7.Fhir.Model.CodeableConcept>(ReasonCode.DeepCopy());
            }
            if (ReasonReference != null)
            {
                dest.ReasonReference = new List <Hl7.Fhir.Model.ResourceReference>(ReasonReference.DeepCopy());
            }
            if (ManagingOrganization != null)
            {
                dest.ManagingOrganization = new List <Hl7.Fhir.Model.ResourceReference>(ManagingOrganization.DeepCopy());
            }
            if (Telecom != null)
            {
                dest.Telecom = new List <Hl7.Fhir.Model.ContactPoint>(Telecom.DeepCopy());
            }
            if (Note != null)
            {
                dest.Note = new List <Hl7.Fhir.Model.Annotation>(Note.DeepCopy());
            }
            return(dest);
        }