예제 #1
0
        static void Main()
        {
            // 初始化用户信息
            DepositCard depo     = new DepositCard(10000);
            CreditCard  cred     = new CreditCard(9, 5000, 100);
            Accounts    accounts = new Accounts(depo, cred);
            Client      client   = new Client("Hazel", accounts);
            // 委托类实例化
            Delegate repayDelegate = new Delegate();
            // 进入菜单
            Menu menu = new Menu();

            menu.HomePage(client, repayDelegate);
        }
예제 #2
0
 // 账户类构造函数
 internal Accounts(DepositCard deposit, CreditCard credit)
 {
     depo = deposit;
     cred = credit;
 }