Home > nifty-tou > TemporalRangesTariffSchedule > firstMatch
Find the first rule that applies on a given date.
Signature:
firstMatch(date: Date, utc?: boolean): T | undefined;
Parameter | Type | Description |
---|---|---|
date | Date | the date to find the first matching rule at |
utc | boolean | (Optional) if true then use UTC date components, otherwise assume the local time zone |
Returns:
T | undefined
the first available matching rule, or undefined
if no rules match