Package org.onebusaway.transit_data_federation.services.tripplanner

Examples of org.onebusaway.transit_data_federation.services.tripplanner.TransferPatternService


  public Collection<Edge> getIncoming() {

    List<Edge> edges = new ArrayList<Edge>();

    if (_pathState.hasTransfers()) {
      TransferPatternService tpService = _context.getTransferPatternService();
      List<TPState> transferStates = _pathState.getTransferStates(tpService);
      for (TPState nextState : transferStates) {
        Edge edge = new TPTransferEdge(_context, _pathState, nextState,
            _departure, _arrival, true);
        edges.add(edge);
View Full Code Here


  public Collection<Edge> getOutgoing() {

    List<Edge> edges = new ArrayList<Edge>();

    if (_pathState.hasTransfers()) {
      TransferPatternService tpService = _context.getTransferPatternService();
      List<TPState> transferStates = _pathState.getTransferStates(tpService);
      for (TPState nextState : transferStates) {
        TPTransferEdge edge = new TPTransferEdge(_context, _pathState,
            nextState, _departure, _arrival, false);
        edge.setFromVertex(this);
View Full Code Here

     * proceed.
     */
    if (_isReverseEdge && s0.getNumBoardings() > 0)
      return null;

    TransferPatternService tpService = _context.getTransferPatternService();
    if (tpService.isEnabled())
      return traverseBackTransferPatterns(s0, options);

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

      Vertex toVertex = new WalkFromStopVertex(_context, _stop);
      EdgeNarrative narrative = narrative(s0, fromVertex, toVertex);
      return s0.edit(this, narrative).makeState();
    }

    TransferPatternService tpService = _context.getTransferPatternService();

    TPQueryData queryData = options.getExtension(TPQueryData.class);

    List<StopEntry> sourceStops = queryData.getSourceStops();

    State results = null;

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

    for (TransferNode tree : trees) {

      TPState pathState = TPState.end(queryData, tree);
View Full Code Here

     *
     */
    if (!_isReverseEdge && s0.getNumBoardings() > 0)
      return null;

    TransferPatternService tpService = _context.getTransferPatternService();
    if (tpService.isEnabled())
      return traverseTransferPatterns(s0, options);

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

    if (_isReverseEdge) {
      EdgeNarrative narrative = createNarrative(s0);
      return s0.edit(this, narrative).makeState();
    }

    TransferPatternService tpService = _context.getTransferPatternService();

    TPQueryData queryData = options.getExtension(TPQueryData.class);

    List<StopEntry> destStops = queryData.getDestStops();

    State results = null;

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

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

      TPState pathState = TPState.start(queryData, tree);
View Full Code Here

TOP

Related Classes of org.onebusaway.transit_data_federation.services.tripplanner.TransferPatternService

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.