Package org.onebusaway.transit_data_federation.impl.otp.graph.tp

Examples of org.onebusaway.transit_data_federation.impl.otp.graph.tp.TPState


  private double computeWeight(State state, Vertex target, Vertex v) {

    if (v instanceof HasPathStateVertex) {
      HasPathStateVertex tpV = (HasPathStateVertex) v;

      TPState pathState = tpV.getPathState();
      TransferNode node = pathState.getNode();

      boolean isFromSourceStop = tpV.isDeparture() ^ pathState.isReverse();

      CoordinatePoint dest = new CoordinatePoint(target.getY(), target.getX());
      Set<TransferNode> visitedNodes = new HashSet<TransferNode>();
      return getWeightForTransferNode(null, node, isFromSourceStop, dest,
          visitedNodes);
View Full Code Here


    Collection<TransferNode> trees = tpService.getReverseTransferPatternsForStops(
        queryData.getTransferPatternData(), sourceStops, _stop);

    for (TransferNode tree : trees) {

      TPState pathState = TPState.end(queryData, tree);

      Vertex fromVertex = new TPArrivalVertex(_context, pathState);
      Vertex toVertex = new WalkFromStopVertex(_context, _stop);

      EdgeNarrative narrative = narrative(s0, fromVertex, toVertex);
View Full Code Here

    TransferParent transfers = tpService.getTransferPatternsForStops(
        queryData.getTransferPatternData(), _stop, destStops);

    for (TransferNode tree : transfers.getTransfers()) {

      TPState pathState = TPState.start(queryData, tree);

      Vertex fromVertex = new WalkToStopVertex(_context, _stop);
      Vertex toVertex = new TPDepartureVertex(_context, pathState);
      EdgeNarrative narrative = narrative(s0, fromVertex, toVertex);
View Full Code Here

TOP

Related Classes of org.onebusaway.transit_data_federation.impl.otp.graph.tp.TPState

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.