예제 #1
0
		public static TaxDetailEntity ToDataModel(this TaxDetail taxDetail)
		{
			if (taxDetail == null)
				throw new ArgumentNullException("taxDetail");

			var retVal = new TaxDetailEntity();
			retVal.InjectFrom(taxDetail);
			return retVal;
		}
예제 #2
0
        public virtual void Patch(TaxDetailEntity target)
        {
            if (target == null)
            {
                throw new ArgumentNullException(nameof(target));
            }

            target.Rate   = Rate;
            target.Amount = Amount;
        }
예제 #3
0
			/// <summary>
		/// Patch CatalogBase type
		/// </summary>
		/// <param name="source"></param>
		/// <param name="target"></param>
		public static void Patch(this TaxDetailEntity source, TaxDetailEntity target)
		{
			if (target == null)
				throw new ArgumentNullException("target");


			var patchInjectionPolicy = new PatchInjection<TaxDetailEntity>(x => x.Rate, x => x.Amount);
			target.InjectFrom(patchInjectionPolicy, source);

		}