A textual representation of this instance.
Calling this property directly is discouraged. Instead, convert an
instance of any type to a string by using the `String(describing:)`
initializer. This initializer works with any type, and uses the custom
`description` property for types that conform to
`CustomStringConvertible`:
struct Point: CustomStringConvertible {
let x: Int, y: Int
var description: String {
return "(\(x), \(y))"
}
}
let p = Point(x: 21, y: 30)
let s = String(describing: p)
print(s)
// Prints "(21, 30)"
The conversion of `p` to a string in the assignment to `s` uses the
`Point` type's `description` property.
get · iOS 18.2+
occurrences
TypeScript
get occurrences(): (number) | null
Swift declaration
var occurrences: Int? { get }
At most many times the event may occur
This value is set when the struct was initialized with `.afterOccurrences()`
The event stops repeating after a given number of times
- Parameter count: how many times to repeat the event, including
the first occurrence. `count` must be greater
than `0`
get · iOS 18.2+
date
TypeScript
get date(): (globalThis.Date) | null
Swift declaration
var date: Date? { get }
The latest date when the event may occur
This value is set when the struct was initialized with `.afterDate()`
get · iOS 18.0+
never
TypeScript
static get never(): Calendar_RecurrenceRule_End
Swift declaration
static var never: Calendar.RecurrenceRule.End { get }
The event stops repeating after a given date
- Parameter date: the date on which the event may last occur. No
further occurrences will be found after that