示例#1
0
        private void RecordDeposit(Guid recipientId, decimal amount, DateTime timestamp)
        {
            CurrentBalance += amount;
            var record = new AccountLog(timestamp, amount, CurrentBalance, recipientId);

            History.Add(record);
        }
示例#2
0
        private void RecordWithdrawal(Guid accountId, decimal amount, DateTime timestamp)
        {
            CurrentBalance -= amount;
            var record = new AccountLog(timestamp, -amount, CurrentBalance, accountId);

            History.Add(record);
        }