raptor
    Preparing search index...

    Class McRAPTOR<TimeVal, V, CA, SI, RI, TI>

    Type Parameters

    • TimeVal
    • V extends Ordered<V>
    • CA extends [V, string][]
    • SI extends Id = Id
    • RI extends Id = Id
    • TI extends Id = Id

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    bags: Map<SI, Bag<JourneyStep<TimeVal, SI, RI, V, CA>>>[] = []

    A Label Bags_i(SI) stores earliest known arrival times and best values for criteria at stop SI with up to i trips.

    Bpt: null | Bag<JourneyStep<TimeVal, SI, RI, V, CA>> = null
    criteria: {
        [K in string | number | symbol]: Criterion<
            TimeVal,
            SI,
            RI,
            CA[K<K>][0],
            CA[K<K>][1],
        >
    }
    k: number = 0

    Round k <=> at most k transfers

    marked: Set<SI> = ...
    runParams:
        | null
        | {
            departureTime: TimeVal;
            ps: SI;
            pt: SI;
            rounds: number;
            settings: RAPTORRunSettings;
        } = null
    defaultRounds: number = 6

    Accessors

    Methods

    • Returns void

    • Parameters

      • route: Route<TimeVal, SI, RI>
      • p: SI

        Stop Id.

      • after: TimeVal

        Time after which trips should be considered

      • startTripIndex: number = 0

        Trip index to start iterating from

      Returns null | { boardedAt: SI; tripIndex: number }

      The earliest Trip on the route (and its index) r at the stop p, or null if no one is catchable.

      Finds the earliest Trip on route r at stop p departing after after.

    • Parameters

      Returns void

    • Util method to iterate through transfers and stop when required. It takes advantage of the sorting of transfers by ascending transfer length.

      Parameters

      Returns Generator<FootPath<SI>, void, unknown>

      An iterator (generator) through transfers

    • Parameters

      • length: number

        Length of the path, in m.

      Returns number

      Duration in ms