Пример #1
0
 /// <summary>
 /// 6 parameter constructor of a canoe, matches ToString Method
 /// </summary>
 /// <param name="serialNumber">serial number of a canoe</param>
 /// <param name="retailPrice">price we charge retail stores for a canoe</param>
 /// <param name="modelName">model name of a canoe</param>
 /// <param name="canoebrand">brand of a canoe</param>
 /// <param name="canoetype">type of a canoe</param>
 /// <param name="paddleType">paddle type needed with canoe</param>
 public Canoe(string serialNumber, decimal retailPrice, string modelName, CBrand canoebrand, CType canoetype, PType paddleType)
 {
     this.SerialNumber = serialNumber;
     this.RetailPrice  = retailPrice;
     this.ModelName    = modelName;
     this.CanoeBrand   = canoebrand;
     this.CanoeType    = canoetype;
     this.PaddleType   = paddleType;
 }
Пример #2
0
        private const decimal DefaultWholeSalePrice = 200; // Purchase price from manufacter

        #endregion Fields

        #region Constructors

        /// <summary>
        /// Fully qualified constructor of Canoe
        /// </summary>
        /// <param name="serialNumber">serial number of a canoe</param>
        /// <param name="modelName">model name of a canoe</param>
        /// <param name="capacity">max passengers that can fit in a canoe</param>
        /// <param name="wholesalePrice">price we pay manufacturer for a canoe</param>
        /// <param name="retailPrice">price we charge retail stores for a canoe</param>
        /// <param name="length">length of a canoe</param>
        /// <param name="weight">weight of a canoe</param>
        /// <param name="canoebrand">brand of canoe</param>
        /// <param name="canoetype">type of a canoe</param>
        public Canoe(string serialNumber, string modelName, int capacity, decimal wholesalePrice, decimal retailPrice, int length, int weight, CBrand canoebrand, CType canoetype)
        {
            // WaterCraft
            this.SerialNumber = serialNumber;
            this.ModelName = modelName;
            this.PassengerCapacity = capacity;
            this.WholeSalePrice = wholesalePrice;
            this.RetailPrice = retailPrice;
            this.Length = length;
            this.Weight = weight;

            // Specific to Canoe
            this.CanoeBrand = canoebrand;
            this.CanoeType = canoetype;
        }
Пример #3
0
        /// <summary>
        /// Fully qualified constructor of Canoe
        /// </summary>
        /// <param name="serialNumber">serial number of a canoe</param>
        /// <param name="modelName">model name of a canoe</param>
        /// <param name="capacity">max passengers that can fit in a canoe</param>
        /// <param name="wholesalePrice">price we pay manufacturer for a canoe</param>
        /// <param name="retailPrice">price we charge retail stores for a canoe</param>
        /// <param name="length">length of a canoe</param>
        /// <param name="weight">weight of a canoe</param>
        /// <param name="canoebrand">brand of canoe</param>
        /// <param name="canoetype">type of a canoe</param>
        public Canoe(string serialNumber, string modelName, int capacity, decimal wholesalePrice, decimal retailPrice, int length, int weight, CBrand canoebrand, CType canoetype)
        {
            // WaterCraft
            this.SerialNumber      = serialNumber;
            this.ModelName         = modelName;
            this.PassengerCapacity = capacity;
            this.WholeSalePrice    = wholesalePrice;
            this.RetailPrice       = retailPrice;
            this.Length            = length;
            this.Weight            = weight;

            // Specific to Canoe
            this.CanoeBrand = canoebrand;
            this.CanoeType  = canoetype;
        }
Пример #4
0
        /// <summary>
        /// Default constructor of a canoe
        /// </summary>
        /// <param name="serialNumber">serial number of a canoe</param>
        /// <param name="modelName">model name of a canoe</param>
        /// <param name="capacity">max passengers that can fit in a canoe</param>
        /// <param name="wholesalePrice">price we pay manufacturer for a canoe</param>
        /// <param name="retailPrice">price we charge retail stores for a canoe</param>
        /// <param name="length">length of a canoe</param>
        /// <param name="weight">weight of a canoe</param>
        /// <param name="canoebrand">brand of canoe</param>
        /// <param name="canoetype">type of a canoe</param>
        /// <param name="paddleType">paddle type need for canoe</param>
        public Canoe(string serialNumber, string modelName, int capacity, decimal wholesalePrice, decimal retailPrice, int length, int weight, CBrand canoebrand, CType canoetype, PType paddleType)
        {
            // WaterCraft
            this.SerialNumber = DefaultSN;
            this.ModelName = DefaultModelName;
            this.PassengerCapacity = DefaultPassengers;
            this.WholeSalePrice = DefaultWholeSalePrice;
            this.RetailPrice = DefaultRetailPrice;
            this.Length = DefaultLength;
            this.Weight = DefaultWeight;

            // Specific to Canoe
            this.CanoeBrand = DefaultCanoeBrand;
            this.CanoeType = DefaultCanoeType;
            this.PaddleType = DefaultPaddleType;
        }
Пример #5
0
        /// <summary>
        /// Default constructor of a canoe
        /// </summary>
        /// <param name="serialNumber">serial number of a canoe</param>
        /// <param name="modelName">model name of a canoe</param>
        /// <param name="capacity">max passengers that can fit in a canoe</param>
        /// <param name="wholesalePrice">price we pay manufacturer for a canoe</param>
        /// <param name="retailPrice">price we charge retail stores for a canoe</param>
        /// <param name="length">length of a canoe</param>
        /// <param name="weight">weight of a canoe</param>
        /// <param name="canoebrand">brand of canoe</param>
        /// <param name="canoetype">type of a canoe</param>
        /// <param name="paddleType">paddle type need for canoe</param>
        public Canoe(string serialNumber, string modelName, int capacity, decimal wholesalePrice, decimal retailPrice, int length, int weight, CBrand canoebrand, CType canoetype, PType paddleType)
        {
            // WaterCraft
            this.SerialNumber      = DefaultSN;
            this.ModelName         = DefaultModelName;
            this.PassengerCapacity = DefaultPassengers;
            this.WholeSalePrice    = DefaultWholeSalePrice;
            this.RetailPrice       = DefaultRetailPrice;
            this.Length            = DefaultLength;
            this.Weight            = DefaultWeight;

            // Specific to Canoe
            this.CanoeBrand = DefaultCanoeBrand;
            this.CanoeType  = DefaultCanoeType;
            this.PaddleType = DefaultPaddleType;
        }
Пример #6
0
 /// <summary>
 /// 6 parameter constructor of a canoe, matches ToString Method
 /// </summary>
 /// <param name="serialNumber">serial number of a canoe</param>
 /// <param name="retailPrice">price we charge retail stores for a canoe</param>
 /// <param name="modelName">model name of a canoe</param>
 /// <param name="canoebrand">brand of a canoe</param>
 /// <param name="canoetype">type of a canoe</param>
 /// <param name="paddleType">paddle type needed with canoe</param>
 public Canoe(string serialNumber, decimal retailPrice, string modelName, CBrand canoebrand, CType canoetype, PType paddleType)
 {
     this.SerialNumber = serialNumber;
     this.RetailPrice = retailPrice;
     this.ModelName = modelName;
     this.CanoeBrand = canoebrand;
     this.CanoeType = canoetype;
     this.PaddleType = paddleType;
 }