Esempio n. 1
0
 public void Crediter(double montant)
 {
     Solde += montant;
     Transaction trans = new Transaction(montant, TypeTransaction.Debit);
     Transactions.Add(trans);
     OnMonAudit(trans);
 }
Esempio n. 2
0
 public virtual bool Debiter(double montant)
 {
     bool reussite = false;
     if (montant<=Solde)
     {
         Solde -= montant;
         reussite = true;
         Transaction trans = new Transaction(montant, TypeTransaction.Debit);
         Transactions.Add(trans);
         OnMonAudit(trans);
     }
     return reussite;
 }
Esempio n. 3
0
 private void OnMonAudit(Transaction trans)
 {
     if (MonAudit!=null)
     {
         MonAudit(this, new MonAuditEventArgs(this.Numero,trans.ToString()));
     }
 }