Contents

recurrences(of:in:)

Find recurrences of the given date

Declaration

func recurrences(of start: Date, in range: Range<Date>? = nil) -> some Sendable & Sequence<Date>

Parameters

  • start:

    The date which defines the starting point for the recurrence rule.

  • range:

    A range of dates which to search for recurrences. If nil, return all recurrences of the event.

Return Value

A sequence of dates conforming to the recurrence rule, in the given range. An empty sequence if the rule doesn’t match any dates.

Discussion

The calculations are implemented according to RFC-5545 and RFC-7529.