Example #1
0
 public Context(State state)
 {
     this.state = state;
 }
Example #2
0
 public void SetState(State s)
 {
     current = s;
 }
Example #3
0
 public Work()
 {
     current = new ForenoonState();
 }
Example #4
0
 public GoldState(State state)
 {
     this.Balance = state.Balance;
     this.Account = state.Account;
     Interest = 0.05;
     LowerLimit = 1000.00;
     UpperLimit = 1000000.00;
 }
Example #5
0
 public SilverState(State state)
     : this(state.Balance, state.Account)
 {
 }
Example #6
0
 public RedState(State state)
 {
     // Initialize
     this.Balance = state.Balance;
     this.Account = state.Account;
     Interest = 0.00;
     LowerLimit = -100.00;
     UpperLimit = 0.00;
 }