Enumeration
Calendar.Component
iOS 8.0+
iPadOS 8.0+
Mac Catalyst 8.0+
macOS 10.10+
tvOS 9.0+
watchOS 2.0+
An enumeration for the various components of a calendar date.
enum Component
Overview
Several Calendar APIs use either a single unit or a set of units as input to a search algorithm.
See Also
DateComponents
Topics
Enumeration Cases
case calendarIdentifier for the calendar unit.case dayIdentifier for the day unit.case dayOfYearcase eraIdentifier for the era unit.case hourIdentifier for the hour unit.case isLeapMonthcase isRepeatedDaycase minuteIdentifier for the minute unit.case monthIdentifier for the month unit.case nanosecondIdentifier for the nanosecond unit.case quarterIdentifier for the quarter of the calendar.case secondIdentifier for the second unit.case timeZoneIdentifier for the time zone unit.case weekOfMonthIdentifier for the week of the month calendar unit.case weekOfYearIdentifier for the week of the year unit.case weekdayIdentifier for the weekday unit.case weekdayOrdinalIdentifier for the weekday ordinal unit.case yearIdentifier for the year unit.case yearForWeekOfYearIdentifier for the week-counting year unit.
Relationships
Conforms To
Swift.EquatableSwift.HashableSwift.SendableSwift.SendableMetatype