| java.lang.Object org.geotools.data.shapefile.indexed.IndexedFidReader
IndexedFidReader | public class IndexedFidReader implements FIDReader(Code) | | This object reads from a file the fid of a feature in a shapefile.
author: Jesse |
Method Summary | |
public void | close() | public int | currentIndex() Returns the record number of the feature in the shx or shp that
is identified by the the last fid returned by next(). | public long | findFid(String fid) Returns the offset to the location in the SHX file that the fid
identifies. | public long | getCount() Returns the number of Fid Entries in the file. | public int | getRemoves() Returns the number of features that have been removed since the
fid index was regenerated. | public void | goTo(long recno) | public boolean | hasNext() | public String | next() | long | search(long desired, long minRec, long maxRec, long predictedRec) Searches for the desired record.
Parameters: desired - the id of the desired record. Parameters: minRec - the last record that is known to be before thedesired record. Parameters: maxRec - the first record that is known to be after thedesired record. Parameters: predictedRec - the record that is predicted to be the desiredrecord. |
currentIndex | public int currentIndex()(Code) | | Returns the record number of the feature in the shx or shp that
is identified by the the last fid returned by next().
Returns the record number of the feature in the shx or shp thatis identified by the the last fid returned by next(). throws: NoSuchElementException - DOCUMENT ME! |
findFid | public long findFid(String fid) throws IOException(Code) | | Returns the offset to the location in the SHX file that the fid
identifies. This search take logN time.
Parameters: fid - the fid to find. Returns the record number of the record in the SHX file that thefid identifies. Will return -1 if the fid was not found. throws: IOException - throws: IllegalArgumentException - DOCUMENT ME! |
getCount | public long getCount()(Code) | | Returns the number of Fid Entries in the file.
Returns the number of Fid Entries in the file. |
getRemoves | public int getRemoves()(Code) | | Returns the number of features that have been removed since the
fid index was regenerated.
Returns the number of features that have been removed since thefid index was regenerated. |
search | long search(long desired, long minRec, long maxRec, long predictedRec) throws IOException(Code) | | Searches for the desired record.
Parameters: desired - the id of the desired record. Parameters: minRec - the last record that is known to be before thedesired record. Parameters: maxRec - the first record that is known to be after thedesired record. Parameters: predictedRec - the record that is predicted to be the desiredrecord. returns the record number of the feature in the shx file. throws: IOException - |
|
|