Package org.opentripplanner.routing.core

Examples of org.opentripplanner.routing.core.EdgeNarrative


    BlockStopTimeEntry bst = _instance.getBlockStopTime();
    StopTimeEntry stopTime = bst.getStopTime();
    int dwellTime = stopTime.getSlackTime();

    EdgeNarrative narrative = createNarrative(s0);
    StateEditor edit = s0.edit(this, narrative);
    edit.incrementTimeInSeconds(dwellTime);
    edit.incrementWeight(dwellTime);

    return edit.makeState();
View Full Code Here


    int transferTime = ItineraryWeightingLibrary.computeTransferTime(_transfer,
        options);
    int t = transferTime + options.minTransferTime;

    EdgeNarrative narrative = createNarrative(s0, s0.getTime() + t * 1000);

    StateEditor edit = s0.edit(this, narrative);
    edit.incrementTimeInSeconds(t);

    double weight = ItineraryWeightingLibrary.computeTransferWeight(
View Full Code Here

    int transferTime = ItineraryWeightingLibrary.computeTransferTime(_transfer,
        options);
    double weight = ItineraryWeightingLibrary.computeTransferWeight(
        transferTime, options);

    EdgeNarrative narrative = createNarrative(s0, s0.getTime());
    StateEditor edit = s0.edit(this, narrative);
    edit.setTime(_instance.getBestArrivalTime());
    edit.incrementWeight(weight);

    return edit.makeState();
View Full Code Here

    BlockStopTimeEntry bst = _instance.getStopTime();
    StopTimeEntry stopTime = bst.getStopTime();
    int dwellTime = stopTime.getSlackTime();

    EdgeNarrative narrative = createNarrative(s0);
    StateEditor edit = s0.edit(this, narrative);
    edit.incrementTimeInSeconds(dwellTime);
    edit.incrementWeight(dwellTime);
    return edit.makeState();
  }
View Full Code Here

  }

  @Override
  public State traverse(State s0) {

    EdgeNarrative narrative = createNarrative(s0);
    StateEditor edit = s0.edit(this, narrative);
    int runningTime = computeRunningTime();
    edit.incrementTimeInSeconds(runningTime);
    edit.incrementWeight(runningTime);
    return edit.makeState();
View Full Code Here

    long departureTime = instance.getDepartureTime();

    TPOfflineTransferVertex toVertex = new TPOfflineTransferVertex(_context,
        instance);
    EdgeNarrative narrative = narrative(s0, _fromVertex, toVertex);

    OBAStateEditor edit = (OBAStateEditor) s0.edit(this, narrative);
    edit.setTime(departureTime);

    int dwellTime = (int) ((departureTime - time) / 1000);
View Full Code Here

    for (StopTimeInstance instance : _instances) {

      TPOfflineTransferVertex vTransfer = new TPOfflineTransferVertex(_context,
          instance);
      EdgeNarrative nTransfer = narrative(s0, _vFrom, vTransfer);
      StateEditor edit = s0.edit(this, nTransfer);

      long t = instance.getDepartureTime();
      edit.setTime(t);
View Full Code Here

TOP

Related Classes of org.opentripplanner.routing.core.EdgeNarrative

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.