Exemplo n.º 1
0
 /// <summary>
 /// the WithDraw method
 /// </summary>
 /// <param name="amount"></param>
 public void WithDraw(int amount)
 {
     if (amount > 0)
     {
         AccountStatement withdraw = new AccountStatement()
         {
             Amount = -amount,
             Date   = _date.TodayDate()
         };
         _accountStatements.Add(withdraw);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// The Deposit Method
 /// </summary>
 /// <param name="amount"></param>
 public void Deposit(int amount)
 {
     if (amount > 0)
     {
         AccountStatement deposit = new AccountStatement()
         {
             Amount = amount,
             Date   = _date.TodayDate()
         };
         _accountStatements.Add(deposit);
     }
 }