コード例 #1
0
        /// <summary>Creates a copy of a price list</summary>
        public static PriceList Clone(this PriceList prices)
        {
            var l = new PriceList();

            foreach (var p in prices)
            {
                l.Add(p.Clone());
            }
            return(l);
        }
コード例 #2
0
        /// <summary>Creates a price list with base Price elements</summary>
        public static PriceList AsPriceList(this PriceList prices)
        {
            var l = new PriceList();

            foreach (var p in prices)
            {
                l.Add(new Price(p));
            }
            return(l);
        }