|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.h2gis.drivers.shp.internal.IndexFile
public class IndexFile
IndexFile parser for .shx files.
For now, the creation of index files is done in the ShapefileWriter. But this
can be used to access the index.
For details on the index file, see
"ESRI(r)
Shapefile - A Technical Description"
* 'An ESRI White Paper .
May 1997'
| Constructor Summary | |
|---|---|
IndexFile(FileChannel channel)
Load the index file from the given channel. |
|
| Method Summary | |
|---|---|
void |
close()
|
int |
getContentLength(int index)
Get the content length of the given record in bytes, not 16 bit words. |
ShapefileHeader |
getHeader()
Get the header of this index file. |
int |
getOffset(int index)
Get the offset of the record (in 16-bit words). |
int |
getOffsetInBytes(int index)
Get the offset of the record (in real bytes, not 16-bit words). |
int |
getRecordCount()
Get the number of records in this index. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IndexFile(FileChannel channel)
throws IOException
channel - The channel to read from.
IOException - If an error occurs.| Method Detail |
|---|
public ShapefileHeader getHeader()
public void close()
throws IOException
IOExceptionpublic int getRecordCount()
public int getOffset(int index)
throws IOException
index - The index, from 0 to getRecordCount - 1
IOException
public int getOffsetInBytes(int index)
throws IOException
index - The index, from 0 to getRecordCount - 1
IOException
public int getContentLength(int index)
throws IOException
index - The index, from 0 to getRecordCount - 1
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||