|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.data.jdbc.JDBC1DataStore
org.geotools.data.jdbc.JDBC2DataStore
org.geotools.data.jdbc.JDBCDataStore
org.geotools.data.oracle.OracleDataStore
public class OracleDataStore
Field Summary |
---|
Fields inherited from class org.geotools.data.jdbc.JDBC2DataStore |
---|
dataSource |
Fields inherited from class org.geotools.data.jdbc.JDBC1DataStore |
---|
allowWriteOnVolatileFIDs, config, listenerManager, sqlNameEscape, transactionIsolation, TYPE_MAPPINGS, typeHandler |
Constructor Summary | |
---|---|
OracleDataStore(javax.sql.DataSource dataSource,
JDBCDataStoreConfig config)
|
|
OracleDataStore(javax.sql.DataSource dataSource,
java.lang.String schemaName,
java.util.Map fidGeneration)
|
|
OracleDataStore(javax.sql.DataSource dataSource,
java.lang.String namespace,
java.lang.String schemaName,
java.util.Map fidGeneration)
|
Method Summary | |
---|---|
protected boolean |
allowTable(java.lang.String tablename)
Crops non feature type tables. |
protected ReferencedEnvelope |
bounds(Query query)
This is (unfortunately) a copy and paste from PostgisFeatureStore, I simply did not know a better place to put this... |
protected org.opengis.feature.type.AttributeDescriptor |
buildAttributeType(java.sql.ResultSet rs)
Overrides the buildAttributeType method to check for SDO_GEOMETRY columns. |
protected JDBCFeatureWriter |
createFeatureWriter(FeatureReader<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature> fReader,
QueryData queryData)
Returns a Oracle text based feature writer that just issues the sql statements directly, as text. |
void |
createSchema(org.opengis.feature.simple.SimpleFeatureType featureType)
Create a new featureType. |
protected org.opengis.referencing.crs.CoordinateReferenceSystem |
determineCRS(int srid)
|
protected int |
determineSRID(java.lang.String tableName,
java.lang.String geometryColumnName)
Provides a hook for subclasses to determine the SRID of a geometry column. |
protected com.vividsolutions.jts.geom.Envelope |
getEnvelope(java.sql.Connection conn,
org.opengis.feature.simple.SimpleFeatureType schema,
java.lang.String geomName,
SQLBuilder sqlBuilder,
org.opengis.filter.Filter filter)
|
com.vividsolutions.jts.geom.Envelope |
getEnvelope(java.lang.String typeName)
Retrieve approx bounds of all Features. |
FeatureSource<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature> |
getFeatureSource(java.lang.String typeName)
Default implementation based on getFeatureReader and getFeatureWriter. |
protected AttributeIO |
getGeometryAttributeIO(org.opengis.feature.type.AttributeDescriptor type,
QueryData queryData)
Hook to create the geometry attribute IO for a vendor specific data source. |
SQLBuilder |
getSqlBuilder(java.lang.String typeName)
Hook for subclass to return a different sql builder. |
boolean |
sql(Transaction t,
java.lang.String sql)
This is used by helper classes to hammer sql back to the database |
Methods inherited from class org.geotools.data.jdbc.JDBC2DataStore |
---|
createConnection, dispose, finalize |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public OracleDataStore(javax.sql.DataSource dataSource, JDBCDataStoreConfig config) throws java.io.IOException
connectionPool
- config
-
java.io.IOException
public OracleDataStore(javax.sql.DataSource dataSource, java.lang.String schemaName, java.util.Map fidGeneration) throws java.io.IOException
connectionPool
-
DataSourceException
java.io.IOException
public OracleDataStore(javax.sql.DataSource dataSource, java.lang.String namespace, java.lang.String schemaName, java.util.Map fidGeneration) throws java.io.IOException
connectionPool
- namespace
-
DataSourceException
java.io.IOException
Method Detail |
---|
protected boolean allowTable(java.lang.String tablename)
allowTable
in class JDBC1DataStore
tablename
- A table name to check.
JDBC1DataStore.allowTable(java.lang.String)
protected org.opengis.feature.type.AttributeDescriptor buildAttributeType(java.sql.ResultSet rs) throws java.io.IOException
buildAttributeType
in class JDBC1DataStore
rs
- The ResultSet containing the result of a
DatabaseMetaData.getColumns call.
java.io.IOException
- If an error occurs processing the ResultSet.protected org.opengis.referencing.crs.CoordinateReferenceSystem determineCRS(int srid) throws java.io.IOException
java.io.IOException
protected int determineSRID(java.lang.String tableName, java.lang.String geometryColumnName) throws java.io.IOException
JDBC1DataStore
This allows SRIDs to be determined in a Vendor specific way and to be cached by the default implementation. To retreive these srids, get the FeatureTypeInfo object for the table and call getSRID(geometryColumnName). This will allow storage of SRIDs for multiple geometry columns in each table.
If no SRID can be found, subclasses should return -1. The default implementation always returns -1.
determineSRID
in class JDBC1DataStore
tableName
- The name of the table to get the SRID for.geometryColumnName
- The name of the geometry column within the table to get SRID
for.
java.io.IOException
JDBC1DataStore.determineSRID(java.lang.String, java.lang.String)
public SQLBuilder getSqlBuilder(java.lang.String typeName) throws java.io.IOException
JDBC1DataStore
Subclasses requiring a ClientTransactionAccessor should override and instantiate an SQLBuilder with one in the constructor.
getSqlBuilder
in class JDBC1DataStore
typeName
- The typename for the sql builder.
java.io.IOException
- if anything goes wrong.JDBC1DataStore.getSqlBuilder(java.lang.String)
protected AttributeIO getGeometryAttributeIO(org.opengis.feature.type.AttributeDescriptor type, QueryData queryData) throws java.io.IOException
JDBC1DataStore
getGeometryAttributeIO
in class JDBC1DataStore
type
- The AttributeDescriptor to read.queryData
- The connection holder
java.io.IOException
- DOCUMENT ME!org.geotools.data.jdbc.JDBCDataStore#getGeometryAttributeIO(org.geotools.feature.AttributeType, org.geotools.data.jdbc.QueryData)
protected JDBCFeatureWriter createFeatureWriter(FeatureReader<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature> fReader, QueryData queryData) throws java.io.IOException
createFeatureWriter
in class JDBC1DataStore
java.io.IOException
public com.vividsolutions.jts.geom.Envelope getEnvelope(java.lang.String typeName)
This result is suitable for a quick map display, illustrating the data. This value is often stored as metadata in databases such as oraclespatial.
getEnvelope
in class JDBC1DataStore
public boolean sql(Transaction t, java.lang.String sql) throws java.io.IOException, java.sql.SQLException
java.io.IOException
java.sql.SQLException
public void createSchema(org.opengis.feature.simple.SimpleFeatureType featureType) throws java.io.IOException
JDBC1DataStore
Not currently supported - subclass may implement.
createSchema
in interface DataAccess<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature>
createSchema
in class JDBC1DataStore
featureType
- FetureType to add to DataStore
java.io.IOException
- If featureType cannot be createdorg.geotools.data.DataStore#createSchema(org.geotools.feature.FeatureType)
public FeatureSource<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature> getFeatureSource(java.lang.String typeName) throws java.io.IOException
We should be able to optimize this to only get the RowSet once
getFeatureSource
in interface DataStore
getFeatureSource
in class JDBC1DataStore
java.io.IOException
DataStore.getFeatureSource(java.lang.String)
protected ReferencedEnvelope bounds(Query query) throws java.io.IOException
query
-
java.io.IOException
protected com.vividsolutions.jts.geom.Envelope getEnvelope(java.sql.Connection conn, org.opengis.feature.simple.SimpleFeatureType schema, java.lang.String geomName, SQLBuilder sqlBuilder, org.opengis.filter.Filter filter) throws java.sql.SQLException, SQLEncoderException, java.io.IOException, com.vividsolutions.jts.io.ParseException
java.sql.SQLException
SQLEncoderException
java.io.IOException
com.vividsolutions.jts.io.ParseException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |