iOS Developer Library

Developer

EventKit Framework Reference EKRecurrenceEnd Class Reference

Options
Deployment Target:

On This Page
Language:

EKRecurrenceEnd

The EKRecurrenceEnd class defines the end of a recurrence rule defined by an EKRecurrenceRule object. The recurrence end can be specified by a date (date-based) or by a maximum count of occurrences (count-based). An event which is set to never end should have its EKRecurrenceEnd set to nil.

Inheritance


Conforms To


Import Statement


Swift

import EventKit

Objective-C

@import EventKit;

Availability


Available in iOS 4.0 and later.
  • Initializes and returns a date-based recurrence end with a given end date.

    Declaration

    Swift

    class func recurrenceEndWithEndDate(_ endDate: NSDate!) -> AnyObject!

    Objective-C

    + (id)recurrenceEndWithEndDate:(NSDate *)endDate

    Parameters

    endDate

    The end date.

    Return Value

    The initialized recurrence end.

    Discussion

    The end date argument must be a valid NSDate and not nil; otherwise an exception will be raised.

    Import Statement

    Objective-C

    @import EventKit;

    Swift

    import EventKit

    Availability

    Available in iOS 4.0 and later.

  • Initializes and returns a count-based recurrence end with a given maximum occurrence count.

    Declaration

    Swift

    class func recurrenceEndWithOccurrenceCount(_ occurrenceCount: Int) -> AnyObject!

    Objective-C

    + (id)recurrenceEndWithOccurrenceCount:(NSUInteger)occurrenceCount

    Parameters

    occurrenceCount

    The maximum occurrence count.

    Return Value

    The initialized recurrence end.

    Discussion

    The maximum occurrence count argument must be a positive integer and not 0; otherwise an exception will be raised.

    Import Statement

    Objective-C

    @import EventKit;

    Swift

    import EventKit

    Availability

    Available in iOS 4.0 and later.

  • endDate endDate Property

    The end date of the recurrence end, or nil if the recurrence end is count-based. (read-only)

    Declaration

    Swift

    var endDate: NSDate! { get }

    Objective-C

    @property(nonatomic, readonly) NSDate *endDate

    Import Statement

    Objective-C

    @import EventKit;

    Swift

    import EventKit

    Availability

    Available in iOS 4.0 and later.

  • The occurrence count of the recurrence end, or 0 if the recurrence end is date-based. (read-only)

    Declaration

    Swift

    var occurrenceCount: Int { get }

    Objective-C

    @property(nonatomic, readonly) NSUInteger occurrenceCount

    Import Statement

    Objective-C

    @import EventKit;

    Swift

    import EventKit

    Availability

    Available in iOS 4.0 and later.