Exemplo n.º 1
0
 public override void ProcessRequest(PurchaseOrder purchase)
 {
     if (purchase.Price < 2500)
     {
         Console.WriteLine("{0} approved purchase request #{1}",
                           this.GetType().Name, purchase.RequestNumber);
     }
     else if (Supervisor != null)
     {
         Supervisor.ProcessRequest(purchase);
     }
 }
 public override void ProcessRequest(PurchaseOrder order)
 {
     if (order.price < 20000)
     {
         Console.WriteLine("Order# " + order.orderNumber + " processed by " + this.GetType().Name);
     }
     else
     if (Supervisor != null)
     {
         Supervisor.ProcessRequest(order);
     }
 }