public override customer CreateCustomer() { silverCustomer objCust = new silverCustomer(); objCust.SilverOperation(); return(objCust); }
public static customer GetCustomer(int i) { switch (i) { case 1: goldCustomer goldCustomer = new goldCustomer(); goldCustomer.GoldOperation(); goldCustomer.AddPoints(); goldCustomer.AddDiscount(); return(goldCustomer); case 2: silverCustomer silverCustomer = new silverCustomer(); silverCustomer.SilverOperation(); silverCustomer.AddPoints(); silverCustomer.AddDiscount(); return(silverCustomer); default: return(null); } }