Ejemplo n.º 1
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Attachment;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (ContentTypeElement != null)
                {
                    dest.ContentTypeElement = (Hl7.Fhir.Model.Code)ContentTypeElement.DeepCopy();
                }
                if (LanguageElement != null)
                {
                    dest.LanguageElement = (Hl7.Fhir.Model.Code)LanguageElement.DeepCopy();
                }
                if (DataElement != null)
                {
                    dest.DataElement = (Hl7.Fhir.Model.Base64Binary)DataElement.DeepCopy();
                }
                if (UrlElement != null)
                {
                    dest.UrlElement = (Hl7.Fhir.Model.FhirUri)UrlElement.DeepCopy();
                }
                if (SizeElement != null)
                {
                    dest.SizeElement = (Hl7.Fhir.Model.UnsignedInt)SizeElement.DeepCopy();
                }
                if (HashElement != null)
                {
                    dest.HashElement = (Hl7.Fhir.Model.Base64Binary)HashElement.DeepCopy();
                }
                if (TitleElement != null)
                {
                    dest.TitleElement = (Hl7.Fhir.Model.FhirString)TitleElement.DeepCopy();
                }
                if (CreationElement != null)
                {
                    dest.CreationElement = (Hl7.Fhir.Model.FhirDateTime)CreationElement.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Ejemplo n.º 2
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as SampledData;

            if (dest != null)
            {
                base.CopyTo(dest);
                if (Origin != null)
                {
                    dest.Origin = (Hl7.Fhir.Model.SimpleQuantity)Origin.DeepCopy();
                }
                if (PeriodElement != null)
                {
                    dest.PeriodElement = (Hl7.Fhir.Model.FhirDecimal)PeriodElement.DeepCopy();
                }
                if (FactorElement != null)
                {
                    dest.FactorElement = (Hl7.Fhir.Model.FhirDecimal)FactorElement.DeepCopy();
                }
                if (LowerLimitElement != null)
                {
                    dest.LowerLimitElement = (Hl7.Fhir.Model.FhirDecimal)LowerLimitElement.DeepCopy();
                }
                if (UpperLimitElement != null)
                {
                    dest.UpperLimitElement = (Hl7.Fhir.Model.FhirDecimal)UpperLimitElement.DeepCopy();
                }
                if (DimensionsElement != null)
                {
                    dest.DimensionsElement = (Hl7.Fhir.Model.PositiveInt)DimensionsElement.DeepCopy();
                }
                if (DataElement != null)
                {
                    dest.DataElement = (Hl7.Fhir.Model.FhirString)DataElement.DeepCopy();
                }
                return(dest);
            }
            else
            {
                throw new ArgumentException("Can only copy to an object of the same type", "other");
            }
        }
Ejemplo n.º 3
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Signature;

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

            base.CopyTo(dest);
            if (Type != null)
            {
                dest.Type = new List <Hl7.Fhir.Model.Coding>(Type.DeepCopy());
            }
            if (WhenElement != null)
            {
                dest.WhenElement = (Hl7.Fhir.Model.Instant)WhenElement.DeepCopy();
            }
            if (Who != null)
            {
                dest.Who = (Hl7.Fhir.Model.ResourceReference)Who.DeepCopy();
            }
            if (OnBehalfOf != null)
            {
                dest.OnBehalfOf = (Hl7.Fhir.Model.ResourceReference)OnBehalfOf.DeepCopy();
            }
            if (TargetFormatElement != null)
            {
                dest.TargetFormatElement = (Hl7.Fhir.Model.Code)TargetFormatElement.DeepCopy();
            }
            if (SigFormatElement != null)
            {
                dest.SigFormatElement = (Hl7.Fhir.Model.Code)SigFormatElement.DeepCopy();
            }
            if (DataElement != null)
            {
                dest.DataElement = (Hl7.Fhir.Model.Base64Binary)DataElement.DeepCopy();
            }
            return(dest);
        }
Ejemplo n.º 4
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Binary;

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

            base.CopyTo(dest);
            if (ContentTypeElement != null)
            {
                dest.ContentTypeElement = (Hl7.Fhir.Model.Code)ContentTypeElement.DeepCopy();
            }
            if (SecurityContext != null)
            {
                dest.SecurityContext = (Hl7.Fhir.Model.ResourceReference)SecurityContext.DeepCopy();
            }
            if (DataElement != null)
            {
                dest.DataElement = (Hl7.Fhir.Model.Base64Binary)DataElement.DeepCopy();
            }
            return(dest);
        }
Ejemplo n.º 5
0
        public override IDeepCopyable CopyTo(IDeepCopyable other)
        {
            var dest = other as Attachment;

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

            base.CopyTo(dest);
            if (ContentTypeElement != null)
            {
                dest.ContentTypeElement = (Hl7.Fhir.Model.Code)ContentTypeElement.DeepCopy();
            }
            if (LanguageElement != null)
            {
                dest.LanguageElement = (Hl7.Fhir.Model.Code)LanguageElement.DeepCopy();
            }
            if (DataElement != null)
            {
                dest.DataElement = (Hl7.Fhir.Model.Base64Binary)DataElement.DeepCopy();
            }
            if (UrlElement != null)
            {
                dest.UrlElement = (Hl7.Fhir.Model.FhirUrl)UrlElement.DeepCopy();
            }
            if (SizeElement != null)
            {
                dest.SizeElement = (Hl7.Fhir.Model.Integer64)SizeElement.DeepCopy();
            }
            if (HashElement != null)
            {
                dest.HashElement = (Hl7.Fhir.Model.Base64Binary)HashElement.DeepCopy();
            }
            if (TitleElement != null)
            {
                dest.TitleElement = (Hl7.Fhir.Model.FhirString)TitleElement.DeepCopy();
            }
            if (CreationElement != null)
            {
                dest.CreationElement = (Hl7.Fhir.Model.FhirDateTime)CreationElement.DeepCopy();
            }
            if (HeightElement != null)
            {
                dest.HeightElement = (Hl7.Fhir.Model.PositiveInt)HeightElement.DeepCopy();
            }
            if (WidthElement != null)
            {
                dest.WidthElement = (Hl7.Fhir.Model.PositiveInt)WidthElement.DeepCopy();
            }
            if (FramesElement != null)
            {
                dest.FramesElement = (Hl7.Fhir.Model.PositiveInt)FramesElement.DeepCopy();
            }
            if (DurationElement != null)
            {
                dest.DurationElement = (Hl7.Fhir.Model.FhirDecimal)DurationElement.DeepCopy();
            }
            if (PagesElement != null)
            {
                dest.PagesElement = (Hl7.Fhir.Model.PositiveInt)PagesElement.DeepCopy();
            }
            return(dest);
        }