Beispiel #1
0
 public Biscuit(string biscuitName, string companyName, OurDate productionDate, OurDate expireDate, double price)
 {
     this.biscuitName    = biscuitName;
     this.companyName    = companyName;
     this.productionDate = productionDate;
     this.expireDate     = expireDate;
     this.price          = price;
 }
Beispiel #2
0
        public static void Main(string[] args)
        {
            OurDate biscuitOneProductionDate = new OurDate(10, 3, 19);
            OurDate biscuitOneExpireDate     = new OurDate(13, 3, 19);
            Biscuit biscuitOne = new Biscuit();

            biscuitOne.SetBiscuitName("Parle G");
            biscuitOne.SetCompanyName("Parle Com");
            biscuitOne.SetProductionDate(biscuitOneProductionDate);
            biscuitOne.SetExpireDate(biscuitOneExpireDate);
            biscuitOne.SetPrice(322.22);
            biscuitOne.DisplayInfo();


            OurDate biscuitTwoProductionDate = new OurDate(10, 3, 19);
            OurDate biscuitTwoExpireDate     = new OurDate(13, 3, 19);
            Biscuit biscuitTwo = new Biscuit("Oreo", "Nabisco", biscuitTwoProductionDate, biscuitTwoExpireDate, 199.55);

            biscuitTwo.DisplayInfo();
        }
Beispiel #3
0
 public void SetExpireDate(OurDate expireDate)
 {
     this.expireDate = expireDate;
 }
Beispiel #4
0
 public void SetProductionDate(OurDate productionDate)
 {
     this.productionDate = productionDate;
 }