Can anyone please explain the purpose of using the syntax like this :
public ClassConstructor() :
this(Guid.NewGuid(), 0, new List<Transaction>(), "")
{
}
The code looks like this :
public BankAccount()
: this(Guid.NewGuid(), 0, new List<Transaction>(), "")
{
_transactions.Add(new Transaction(0m, 0m, "account created", DateTime.Now));
}
public BankAccount(Guid Id, decimal balance, IList<Transaction> transactions, string customerRef)
{
AccountNo = Id;
_balance = balance;
_transactions = transactions;
_customerRef = customerRef;
}