CalendarPeriodSelector
public struct CalendarPeriodSelector : TimeIntervalSelector
Generates time intervals based on a monthly (usually 1, 2, 3, 4, 6 months) or yearly period, optionally considering a calendar offset (as reference for counting months) and a month offset (between 0 and <28 days).
-
Undocumented
Declaration
Swift
public init(for period: Int = 1, in unit: CalendarTimeUnit = .months, origin: Time = .referenceMonthStart, calendarOffset: Int = 0, calendarOffsetIn calendarOffsetUnit: CalendarTimeUnit = .months, offset: Double = 0, offsetIn offsetUnit: TimeUnit = .seconds)
-
Undocumented
Declaration
Swift
public var period: Int
-
Undocumented
Declaration
Swift
public var unit: CalendarTimeUnit
-
Undocumented
Declaration
Swift
public var origin: Time
-
Returns repeating calendar times (based on months) within the input interval, given the specified period, the calendar time unit to use for interpreting the period value, and the origin time to serve as periodical phase (if specified).