public override IDeepCopyable CopyTo(IDeepCopyable other) { var dest = other as CarePlanActivitySimpleComponent; if (dest != null) { base.CopyTo(dest); if (CategoryElement != null) { dest.CategoryElement = (Code <Hl7.Fhir.Model.CarePlan.CarePlanActivityCategory>)CategoryElement.DeepCopy(); } if (Code != null) { dest.Code = (Hl7.Fhir.Model.CodeableConcept)Code.DeepCopy(); } if (Timing != null) { dest.Timing = (Hl7.Fhir.Model.Element)Timing.DeepCopy(); } if (Location != null) { dest.Location = (Hl7.Fhir.Model.ResourceReference)Location.DeepCopy(); } if (Performer != null) { dest.Performer = new List <Hl7.Fhir.Model.ResourceReference>(Performer.DeepCopy()); } if (Product != null) { dest.Product = (Hl7.Fhir.Model.ResourceReference)Product.DeepCopy(); } if (DailyAmount != null) { dest.DailyAmount = (Hl7.Fhir.Model.Quantity)DailyAmount.DeepCopy(); } if (Quantity != null) { dest.Quantity = (Hl7.Fhir.Model.Quantity)Quantity.DeepCopy(); } if (DetailsElement != null) { dest.DetailsElement = (Hl7.Fhir.Model.FhirString)DetailsElement.DeepCopy(); } return(dest); } else { throw new ArgumentException("Can only copy to an object of the same type", "other"); } }
public void Then_daily_amount_should_be_set() { SUT.Snapshot.Daily.ShouldBeGreaterThan(DailyAmount.FromDecimal(0m)); }
public void Then_daily_amount_should_equal_zero() { SUT.Snapshot.Daily.ShouldEqual(DailyAmount.FromDecimal(0m)); }
public void Then_snapshot_should_be_changed() { SUT.Snapshot.Daily.ShouldEqual(DailyAmount.FromDecimal(3.33m)); }
public void Then_snapshot_should_be_updated() { var expected = (100 - 50) / 10; SUT.Snapshot.Daily.ShouldEqual(DailyAmount.FromDecimal(expected)); }
public void Then_snapshot_should_be_updated() { SUT.Snapshot.Daily.ShouldBeLessThan(DailyAmount.FromDecimal(10m)); }
public void Then_snapshot_should_be_updated() { SUT.Snapshot.Daily.ShouldEqual(DailyAmount.FromDecimal(0m)); }
public void Then_daily_amount_should_be_doubled() { SUT.Snapshot.Daily.ShouldEqual(DailyAmount.FromDecimal(20m)); }
public override ErrorList Validate() { var result = new ErrorList(); result.AddRange(base.Validate()); if (CategoryElement != null) { result.AddRange(CategoryElement.Validate()); } if (Code != null) { result.AddRange(Code.Validate()); } if (StatusElement != null) { result.AddRange(StatusElement.Validate()); } if (ProhibitedElement != null) { result.AddRange(ProhibitedElement.Validate()); } if (Timing != null) { result.AddRange(Timing.Validate()); } if (Location != null) { result.AddRange(Location.Validate()); } if (Performer != null) { Performer.ForEach(elem => result.AddRange(elem.Validate())); } if (Product != null) { result.AddRange(Product.Validate()); } if (DailyAmount != null) { result.AddRange(DailyAmount.Validate()); } if (Quantity != null) { result.AddRange(Quantity.Validate()); } if (DetailsElement != null) { result.AddRange(DetailsElement.Validate()); } if (ActionTaken != null) { ActionTaken.ForEach(elem => result.AddRange(elem.Validate())); } if (NotesElement != null) { result.AddRange(NotesElement.Validate()); } return(result); }