Exemplo n.º 1
0
 public void DoAccountDeposit(uint accountID, [FromBody] uint amount)
 {
     try
     {
         access.SelectAccount(accountID);
         access.Deposit(amount);
     }
     catch (Exception)
     {
         var response = new HttpResponseMessage(HttpStatusCode.NotFound)
         {
             Content      = new StringContent("Could not perform deposit in account"),
             ReasonPhrase = "Account could not be found"
         };
         throw new HttpResponseException(response);
     }
 }
Exemplo n.º 2
0
 public void Deposit(uint amount)
 {
     accountAccess.Deposit(amount);
     bankDb.SaveToDisk();
 }
Exemplo n.º 3
0
 public void Deposit(uint amount)
 {
     accountAccess.Deposit(amount);
 }