public static HourlyEmployee CreateNew(EmployeeId employeeId, Name name, Address address, HourlyRate rate) { return(new HourlyEmployee(employeeId, name, address, rate)); }
private HourlyEmployee(EmployeeId employeeId, Name name, Address address, HourlyRate rate) : base(employeeId, name, address) { rate.EnsureNotNull("Hourly rate must not be null."); Rate = rate; }