Package org.onebusaway.transit_data_federation.impl.blocks

Examples of org.onebusaway.transit_data_federation.impl.blocks.BlockSequence


  }

  @Override
  public String toString() {

    BlockSequence first = _sequences.get(0);
    BlockConfigurationEntry blockConfig = first.getBlockConfig();
    BlockEntry block = blockConfig.getBlock();
    List<BlockStopTimeEntry> bsts = first.getStopTimes();
    BlockStopTimeEntry firstBst = bsts.get(0);
    BlockStopTimeEntry lastBst = bsts.get(bsts.size() - 1);
    StopEntry fromStop = firstBst.getStopTime().getStop();
    StopEntry toStop = lastBst.getStopTime().getStop();
    return "BlockSequenceIndex [ex: block=" + block.getId() + " fromStop="
View Full Code Here


      BlockConfigurationEntry... blocks) {

    List<BlockStopTimeEntry> stopTimes = blocks[0].getStopTimes();
    List<BlockSequence> sequences = new ArrayList<BlockSequence>();
    for (BlockConfigurationEntry blockConfig : blocks) {
      BlockSequence sequence = new BlockSequence(blockConfig, 0,
          stopTimes.size());
      sequences.add(sequence);
    }

    return _factory.createSequenceIndexForGroupOfBlockSequences(sequences);
View Full Code Here

  }

  @Override
  public int getArrivalTimeForIndex(int index) {
    List<BlockSequence> sequences = _index.getSequences();
    BlockSequence sequence = sequences.get(index);
    return sequence.getArrivalTimeForIndex(_offset);
  }
View Full Code Here

  }

  @Override
  public int getDepartureTimeForIndex(int index) {
    List<BlockSequence> sequences = _index.getSequences();
    BlockSequence sequence = sequences.get(index);
    return sequence.getDepartureTimeForIndex(_offset);
  }
View Full Code Here

  }

  @Override
  public String toString() {
    List<BlockSequence> sequences = _index.getSequences();
    BlockSequence sequence = sequences.get(0);
    List<BlockStopTimeEntry> stopTimes = sequence.getStopTimes();
    BlockStopTimeEntry bst = stopTimes.get(_offset);
    return bst.toString();
  }
View Full Code Here

  private class ListImpl extends AbstractList<BlockStopTimeEntry> {

    @Override
    public BlockStopTimeEntry get(int index) {
      List<BlockSequence> sequences = _index.getSequences();
      BlockSequence sequence = sequences.get(index);
      return sequence.getStopTimes().get(_offset);
    }
View Full Code Here

TOP

Related Classes of org.onebusaway.transit_data_federation.impl.blocks.BlockSequence

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.