DLSEntry

Objective-C

@interface DLSEntry : StopVisits

Swift

class DLSEntry : StopVisits

A DLSEntry represents the connection of a particular service starting at a particular stop and going all the way an end stop without the passanger having to get off.

Note

The arrival represents arriving at the endStop not arriving at the starting stop as is the case for usual instances of StopVisits. This means that arrival is always after (or at the same time as) as departure.

Note

The service might not be the same when arriving at endStop but it can instead be one of the start’s

  • Indexed identifier to quickly look up entries for a particular pair of stops.

    Declaration

    Objective-C

    @property (nonatomic, retain) NSString *_Nonnull pairIdentifier;

    Swift

    var pairIdentifier: String { get set }
  • The destination. It should not be a parent stop. The time to get off is the arrival of this DLSEntry.

    See

    StopVisit superclass

    Declaration

    Objective-C

    @property (nonatomic, retain) StopLocation *_Nonnull endStop;

    Swift

    var endStop: StopLocation { get set }
  • Creates a predicate to query the database for DLS entries for the specified list of pair identifiers after the given date and using the specific filter.

    Declaration

    Objective-C

    + (nonnull NSPredicate *)
        departuresPredicateForPairs:(nonnull NSSet<NSString *> *)pairs
                           fromDate:(nonnull NSDate *)date
                             filter:(nullable NSString *)filter;

    Swift

    class func departuresPredicate(forPairs pairs: Set<String>, from date: Date, filter: String?) -> NSPredicate

    Parameters

    pairs

    Strings matched against the pairIdentifier of the DLS entries.

    date

    Starting date and time.

    filter

    Filter which the returnes DLS entries must match.

    Return Value

    Predicate to query CoreData with

  • Undocumented

    Declaration

    Objective-C

    + (NSArray<DLSEntry *> *)fetchDLSEntriesPairs:(NSSet<NSString *> *)pairs
                                         fromDate:(NSDate *)date
                                            limit:(NSUInteger)limit
                                 inTripKitContext:(NSManagedObjectContext *)context;

    Swift

    class func fetchDLSEntriesPairs(_ pairs: Set<String>, from date: Date, limit: UInt, inTripKitContext context: NSManagedObjectContext) -> [DLSEntry]
  • Undocumented

    Declaration

    Objective-C

    + (void)clearAllEntriesInTripKitContext:(NSManagedObjectContext *)context;

    Swift

    class func clearAllEntries(inTripKitContext context: NSManagedObjectContext)