Table of Contents

Class NmwEvaluator

Namespace
Payetools.NationalMinimumWage
Assembly
Payetools.NationalMinimumWage.dll

Represents a National Minimum/Living Wage evaluator that implements INmwEvaluator.

public class NmwEvaluator : INmwEvaluator
Inheritance
NmwEvaluator
Implements
Inherited Members

Constructors

NmwEvaluator(INmwLevelSet)

Initialises a new instance of NmwEvaluator using the supplied set of levels.

public NmwEvaluator(INmwLevelSet nmwLevels)

Parameters

nmwLevels INmwLevelSet

NMW/NLW levels to use.

Methods

Evaluate(DateRange, DateOnly, decimal, decimal, bool, decimal?)

Evauates whether an employee's pay is compliant with the NMW/NLW regulations by considering their pay, hours and date of birth. Note that apprentices have special treatment.

public NmwEvaluationResult Evaluate(DateRange payPeriod, DateOnly dateOfBirth, decimal grossPay, decimal hoursWorkedForPay, bool isApprentice = false, decimal? yearsAsApprentice = null)

Parameters

payPeriod DateRange

Applicable pay period.

dateOfBirth DateOnly

Employee's date of birth.

grossPay decimal

Gross pay to be used for the evaluation. This pay should correspond to the number of hours worked given in the subequent parameter.

hoursWorkedForPay decimal

Hours worked that corresponds to the gross pay figure supplied.

isApprentice bool

True if the employee is an apprentice; false otherwise. Optional, defaults to false.

yearsAsApprentice decimal?

Number of years an apprentice has served in their apprenticeship. May be a figure less than one. Optional, defaults to null; not required if the employee is not an apprentice.

Returns

NmwEvaluationResult

An instance of NmwEvaluationResult that indicates whether the pay is compliant with the NMW/NLW regulations.

Remarks

As per https://www.gov.uk/hmrc-internal-manuals/national-minimum-wage-manual/nmwm03010, the rate that applies to each worker depends on their age at teh start of the pay reference period.

GetNmwHourlyRateForEmployee(int, bool, decimal?)

Gets the expected hourly rate of pay for an employee that is paid is the National Minimum or National Living Wage.

public decimal GetNmwHourlyRateForEmployee(int ageAtStartOfPeriod, bool isApprentice = false, decimal? yearsAsApprentice = null)

Parameters

ageAtStartOfPeriod int

Age at the start of the applicable pay period.

isApprentice bool

True if the employee is an apprentice; false otherwise. Optional, defaults to false.

yearsAsApprentice decimal?

Number of years an apprentice has served in their apprenticeship. May be a figure less than one. Optional, defaults to null; not required if the employee is not an apprentice.

Returns

decimal

Appropriate hourly rate of pay.

Remarks

As per https://www.gov.uk/hmrc-internal-manuals/national-minimum-wage-manual/nmwm03010, the rate that applies to each worker depends on their age at the start of the pay reference period.