private CustomerStatus(CustomerStatusType type, ExpirationDate expirationDate) : this() { Type = type; _expirationDate = expirationDate ?? throw new ArgumentNullException(nameof(expirationDate)); }
private CustomerStatus(CustomerStatusType type, ExpirationDate expirationDate) : this() { Type = type; ExpirationDate = expirationDate; }
private CustomerStatus(CustomerStatusType type) : this() { Type = type; }
public CustomerStatus Promote() { this.Type = CustomerStatusType.Advanced; this._expirationDate = DateTime.UtcNow.AddYears(1); return(this); }
private CustomerStatus(CustomerStatusType type, ExpirationDate expirationDate) : this() { this.Type = type; this._expirationDate = expirationDate ?? throw new ArgumentEmptyException(nameof(expirationDate)); }
// TODO Criar validador public Customer(string accountNumber, string name, string lastName, int documentId, CustomerStatusType status, Custody custody) { AccountNumber = accountNumber; Name = name; LastName = lastName; DocumentId = documentId; Status = status; Custody = custody; Validate(this, new CustomerValidator()); }