Esempio n. 1
0
        static void Main(string[] args)
        {
            Bank     b2 = BankFactory.getBank("investment");
            IAccount a2 = b2.openAccount("fixed");

            Console.WriteLine(a2.getRate());
        }
Esempio n. 2
0
 static void Main(string[] args)
 {
     try
     {
         Bank     b2 = BankFactory.getBank("investment");
         IAccount a2 = b2.openAccount("fixeded");
         Console.WriteLine(a2.getRate());
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message);
     }
 }