Beispiel #1
0
 public Loan(int numberOfInstallments, double interest, double amount, Guid personId)
 {
     CreationDate           = DateTime.UtcNow;
     NumberOfInstallments   = numberOfInstallments;
     Interest               = interest;
     EstimatedRepaymentDate = CreationDate.AddMonths(numberOfInstallments);
     Amount   = amount;
     PersonId = personId;
 }
Beispiel #2
0
        public Offer(CarConfiguration configuration, decimal price)
        {
            if (configuration == null)
            {
                throw new ArgumentException(nameof(configuration));
            }

            Id             = Guid.NewGuid();
            Configuration  = configuration;
            TotalPrice     = price;
            CreationDate   = DateTime.Now;
            ExpirationDate = CreationDate.AddMonths(DEFAULT_EXPIRATION_TIME_IN_MONTHS);
        }