// Path: salary-slip/src/main/java/salaryslip/SalarySlipBuilder.java
// public static SalarySlipBuilder aSalarySlip() {
//   return new SalarySlipBuilder();
// }


import static salaryslip.SalarySlipBuilder.aSalarySlip;
package salaryslip;


class SalarySlipGenerator {

  private final NationalInsuranceCalculation nationalInsuranceCalculation;
  private final GrossSalaryCalculation grossSalaryCalculation;
  private final TaxFreeAllowanceCalculation taxFreeAllowanceCalculation;
  private final TaxableIncomeCalculation taxableIncomeCalculation;
  private final TaxablePayableCalculation taxablePayableCalculation;

  SalarySlipGenerator(NationalInsuranceCalculation nationalInsuranceCalculation,
                      GrossSalaryCalculation grossSalaryCalculation,
                      TaxFreeAllowanceCalculation taxFreeAllowanceCalculation,
                      TaxableIncomeCalculation taxableIncomeCalculation,
                      TaxablePayableCalculation taxablePayableCalculation) {
    this.nationalInsuranceCalculation = nationalInsuranceCalculation;
    this.grossSalaryCalculation = grossSalaryCalculation;
    this.taxFreeAllowanceCalculation = taxFreeAllowanceCalculation;
    this.taxableIncomeCalculation = taxableIncomeCalculation;
    this.taxablePayableCalculation = taxablePayableCalculation;
  }

  SalarySlip generateFor(Employee employee) {
    AnnualAmount annualSalary = new AnnualAmount(employee.getAnnualSalary());
    MonthlyAmount nationalInsuranceContribution = nationalInsuranceCalculation.execute(annualSalary);
    MonthlyAmount grossSalary = grossSalaryCalculation.execute(annualSalary);
    MonthlyAmount taxFreeAllowance = taxFreeAllowanceCalculation.execute(annualSalary);
    MonthlyAmount taxableIncome = taxableIncomeCalculation.execute(annualSalary);
    MonthlyAmount taxablePayable = taxablePayableCalculation.execute(annualSalary);

// Path: salary-slip/src/main/java/salaryslip/SalarySlipBuilder.java
// public static SalarySlipBuilder aSalarySlip() {
//   return new SalarySlipBuilder();
// }


// Path: salary-slip/src/main/java/salaryslip/SalarySlipGenerator.java
import static salaryslip.SalarySlipBuilder.aSalarySlip;

package salaryslip;


class SalarySlipGenerator {

  private final NationalInsuranceCalculation nationalInsuranceCalculation;
  private final GrossSalaryCalculation grossSalaryCalculation;
  private final TaxFreeAllowanceCalculation taxFreeAllowanceCalculation;
  private final TaxableIncomeCalculation taxableIncomeCalculation;
  private final TaxablePayableCalculation taxablePayableCalculation;

  SalarySlipGenerator(NationalInsuranceCalculation nationalInsuranceCalculation,
                      GrossSalaryCalculation grossSalaryCalculation,
                      TaxFreeAllowanceCalculation taxFreeAllowanceCalculation,
                      TaxableIncomeCalculation taxableIncomeCalculation,
                      TaxablePayableCalculation taxablePayableCalculation) {
    this.nationalInsuranceCalculation = nationalInsuranceCalculation;
    this.grossSalaryCalculation = grossSalaryCalculation;
    this.taxFreeAllowanceCalculation = taxFreeAllowanceCalculation;
    this.taxableIncomeCalculation = taxableIncomeCalculation;
    this.taxablePayableCalculation = taxablePayableCalculation;
  }

  SalarySlip generateFor(Employee employee) {
    AnnualAmount annualSalary = new AnnualAmount(employee.getAnnualSalary());
    MonthlyAmount nationalInsuranceContribution = nationalInsuranceCalculation.execute(annualSalary);
    MonthlyAmount grossSalary = grossSalaryCalculation.execute(annualSalary);
    MonthlyAmount taxFreeAllowance = taxFreeAllowanceCalculation.execute(annualSalary);
    MonthlyAmount taxableIncome = taxableIncomeCalculation.execute(annualSalary);
    MonthlyAmount taxablePayable = taxablePayableCalculation.execute(annualSalary);

    return aSalarySlip()