示例#1
0
        public static void Main(string[] args)
        {
            Approver chainOfApprovers = GetChainOfApprovers();

            Console.WriteLine("PHONE LOAN");
            chainOfApprovers.ApproveLoan(123);

            Console.WriteLine("\nBIKE LOAN");
            chainOfApprovers.ApproveLoan(1234);

            Console.WriteLine("\nHOUSE LOAN");
            chainOfApprovers.ApproveLoan(12345);
        }
示例#2
0
 public void SetNextApprover(Approver a)
 {
     this.nextApprover = a;
 }