Пример #1
0
 private void ProcessChoice(string choice)
 {
     switch (choice)
     {
         case "1":
             Console.WriteLine("This feature is not implemented yet! ");
             Console.WriteLine("Press enter to continue....");
             Console.ReadLine();
             break;
         case "2":
             WithdrawalWorkflow wwf = new WithdrawalWorkflow();
             wwf.Execute(accountNum);
             break;
         case "3":
             Console.WriteLine("This feature is not implemented yet! ");
             Console.WriteLine("Press enter to continue....");
             Console.ReadLine();
             break;
         default:
             Console.WriteLine("{0} is an Invalid entry.", choice);
             Console.WriteLine("Press enter to continue....");
             Console.ReadLine();
             break;
     }
 }
Пример #2
0
        private void ProcessChoice(string input)
        {
            switch (input)
            {
                case "1":
                    var depositWorkflow = new DepositWorkflow();
                    depositWorkflow.Execute(_currentAccount);
                    break;

                case "2":
                    var withdrawalWorkflow = new WithdrawalWorkflow();
                    withdrawalWorkflow.Execute(_currentAccount);
                    break;

                case "3":
                    var transferWorkflow = new TransferWorkflow();
                    transferWorkflow.Execute(_currentAccount);
                    break;

            }
        }