ps6
Class StreetSegReader

java.lang.Object
  extended by ps6.StreetSegReader

public class StreetSegReader
extends Object

A StreetSegReader reads StreetSegments from a set of Tiger Databases.

Specification Fields

Nested Class Summary
static class StreetSegReader.InvalidSourceException
          Exception indicating that the requsted source for a tiger database is invalid
 
Constructor Summary
StreetSegReader(String sourceDirectory)
           
 
Method Summary
 Iterator<StreetSegment> iterator()
          Returns an Iterator over this.streetSegs.
 Iterator<StreetSegment> streetSegments(boolean debug)
          Returns an Iterator over this.streetSegs.
protected  StreetSegIterator streetSegmentsInternal()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreetSegReader

public StreetSegReader(String sourceDirectory)
                throws StreetSegReader.InvalidSourceException
Throws:
StreetSegReader.InvalidSourceException - if sourceDirectory is not valid database (most directories, even empty ones, count as valid).
Effects:
Constructs a StreetSegReader where sourceDirectory contains the Tiger Database files.
Method Detail

iterator

public Iterator<StreetSegment> iterator()
Returns an Iterator over this.streetSegs.

Returns:
an iterator that produces the contents of this.streetSegs. Each element produced by the Iterator is a StreetSegment.

streetSegmentsInternal

protected StreetSegIterator streetSegmentsInternal()

streetSegments

public Iterator<StreetSegment> streetSegments(boolean debug)
Returns an Iterator over this.streetSegs.

Returns:
an iterator that produces the contents of this.streetSegs. Each element produced by the Iterator is a StreetSegment.