Package ch.so.agi.filegdb.table
Class FileGdbTable
java.lang.Object
ch.so.agi.filegdb.table.FileGdbTable
- All Implemented Interfaces:
AutoCloseable,Iterable<FileGdbRow>
Public read access to one dataset of a file geodatabase.
Object ids are one based, matching the file geodatabase object id field.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionFileGdbTable(Dataset dataset) FileGdbTable(Dataset dataset, Map<String, FieldMetadata> metadata, GdbCatalog catalog) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()crs()dataset()Domain assigned to a field, resolved through the catalog.Looks up a field by name, ignoring case as a fallback.fields()Returns the geometry field ornullfor plain tables.intIndex of the geometry field infields(), or -1 for plain tables.booleaniterator()name()intIndex of the object id field infields(), or -1 if absent.path()query(ch.so.agi.filegdb.geometry.Envelope filter) Inclusive geometry-envelope intersection.query(ch.so.agi.filegdb.geometry.Envelope filter, boolean useIndex) read(long objectId) Reads a row by its one based object id, or returnsnullif absent.longrowCount()longMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
FileGdbTable
- Throws:
IOException
-
FileGdbTable
public FileGdbTable(Dataset dataset, Map<String, FieldMetadata> metadata, GdbCatalog catalog) throws IOException- Throws:
IOException
-
-
Method Details
-
dataset
-
name
-
path
-
fields
-
field
Looks up a field by name, ignoring case as a fallback. -
geomField
Returns the geometry field ornullfor plain tables. -
isFeatureClass
public boolean isFeatureClass() -
geomFieldIndex
public int geomFieldIndex()Index of the geometry field infields(), or -1 for plain tables. -
objectIdFieldIndex
public int objectIdFieldIndex()Index of the object id field infields(), or -1 if absent. -
crs
-
domain
Domain assigned to a field, resolved through the catalog. -
rowCount
public long rowCount() -
totalRecordCount
public long totalRecordCount() -
tableFile
-
read
Reads a row by its one based object id, or returnsnullif absent.- Throws:
IOException
-
query
public FileGdbTable.QueryResult query(ch.so.agi.filegdb.geometry.Envelope filter) throws IOException Inclusive geometry-envelope intersection. Foreign geometry-cell indexes cannot prove envelope intersection (e.g. a rectangle inside a polygon hole), so use a scan for those.- Throws:
IOException
-
query
public FileGdbTable.QueryResult query(ch.so.agi.filegdb.geometry.Envelope filter, boolean useIndex) throws IOException - Throws:
IOException
-
iterator
- Specified by:
iteratorin interfaceIterable<FileGdbRow>
-
close
- Specified by:
closein interfaceAutoCloseable- Throws:
IOException
-