org.geotools.data.jdbc
Class JDBC2DataStore

java.lang.Object
  extended by org.geotools.data.jdbc.JDBC1DataStore
      extended by org.geotools.data.jdbc.JDBC2DataStore
All Implemented Interfaces:
DataAccess<org.opengis.feature.simple.SimpleFeatureType,org.opengis.feature.simple.SimpleFeature>, DataStore
Direct Known Subclasses:
JDBCDataStore

Deprecated. scheduled for removal in 2.7, use classes in org.geotools.jdbc

public abstract class JDBC2DataStore
extends JDBC1DataStore

This JDBCDataStore is able to take advantage of additonal functionality provided by JDBC2 level drivers - for example ConnectionPools.

This class provides a default implementation of a JDBC data store. Support for vendor specific JDBC data stores can be easily added to Geotools by subclassing this class and overriding the hooks provided.

At a minimum subclasses should implement the following methods:

Additionally subclasses can optionally override the following:

Additionally subclasses may want to set the value of:

Author:
Amr Alam, Refractions Research, Jody Garnett, Refractions Research

Field Summary
protected  javax.sql.DataSource dataSource
          Deprecated.  
 
Fields inherited from class org.geotools.data.jdbc.JDBC1DataStore
allowWriteOnVolatileFIDs, config, listenerManager, LOGGER, sqlNameEscape, transactionIsolation, TYPE_MAPPINGS, typeHandler
 
Constructor Summary
JDBC2DataStore(javax.sql.DataSource dataSource, JDBCDataStoreConfig config)
          Deprecated. Construct a JDBCDataStore with ConnectionPool and associated configuration.
 
Method Summary
protected  java.sql.Connection createConnection()
          Deprecated. Create a connection for your JDBC1 database
 void dispose()
          Deprecated. Disposes of this data store and releases any resource that it is using.
protected  void finalize()
          Deprecated.  
 
Methods inherited from class org.geotools.data.jdbc.JDBC1DataStore
allowTable, allSameOrder, attributeNames, buildAttributeType, buildFIDMapper, buildFIDMapperFactory, buildSchema, createFeatureReader, createFeatureWriter, createLockingManager, createSchema, determineFidColumnName, determineSRID, executeQuery, executeQuery, getAttributeIO, getAttributeTypes, getConcurrency, getConnection, getDatabaseSchemaName, getEnvelope, getFeatureReader, getFeatureReader, getFeatureSource, getFeatureSource, getFeatureTypeHandler, getFeatureWriter, getFeatureWriter, getFeatureWriterAppend, getFIDMapper, getFIDMapperFactory, getGeometryAttributeIO, getInfo, getJDBCFeatureReader, getLockingManager, getNames, getNameSpace, getResultSetType, getSchema, getSchema, getSqlBuilder, getSqlNameEscape, getSupportedHints, getTransactionIsolation, getTypeNames, getView, propertyNames, requireAutoCommit, setAutoCommit, setFIDMapper, setFIDMapperFactory, setSqlNameEscape, setTransactionIsolation, updateSchema, updateSchema
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dataSource

protected javax.sql.DataSource dataSource
Deprecated. 
Constructor Detail

JDBC2DataStore

public JDBC2DataStore(javax.sql.DataSource dataSource,
                      JDBCDataStoreConfig config)
               throws java.io.IOException
Deprecated. 
Construct a JDBCDataStore with ConnectionPool and associated configuration.

Parameters:
connectionPool -
config -
Throws:
java.io.IOException
Method Detail

createConnection

protected java.sql.Connection createConnection()
                                        throws java.sql.SQLException
Deprecated. 
Create a connection for your JDBC1 database

Specified by:
createConnection in class JDBC1DataStore
Throws:
java.sql.SQLException

finalize

protected void finalize()
                 throws java.lang.Throwable
Deprecated. 
Overrides:
finalize in class java.lang.Object
Throws:
java.lang.Throwable

dispose

public void dispose()
Deprecated. 
Description copied from interface: DataAccess
Disposes of this data store and releases any resource that it is using.

A DataStore cannot be used after dispose has been called, neither can any data access object it helped create, such as FeatureReader, FeatureSource or FeatureCollection.

This operation can be called more than once without side effects.

There is no thread safety assurance associated with this method. For example, client code will have to make sure this method is not called while retrieving/saving data from/to the storage, or be prepared for the consequences.



Copyright © 1996-2010 Geotools. All Rights Reserved.