예제 #1
0
파일: State.cs 프로젝트: agnet/st12
 public State(AccountContext context, int balance)
 {
     Context = context;
     Balance = balance;
 }
예제 #2
0
파일: State.cs 프로젝트: agnet/st12
 public RedState(AccountContext context, int balance)
     : base(context, balance)
 {
 }
예제 #3
0
파일: Program.cs 프로젝트: agnet/st12
 private static void TestState()
 {
     AccountContext account = new AccountContext();
     account.Deposit(100);
     account.Deposit(10);
     account.Withdraw(200);
     account.Deposit(100);
 }