Package org.apache.openjpa.jdbc.kernel
Interface JDBCStore
-
- All Known Implementing Classes:
JDBCStoreManager,SliceStoreManager
public interface JDBCStoreRepresents the JDBC store.- Since:
- 0.4.0
- Author:
- Abe White
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Objectfind(java.lang.Object oid, ValueMapping vm, JDBCFetchConfiguration fetch)Find the object with the given oid.JDBCConfigurationgetConfiguration()Return the configuration for this runtime.java.sql.ConnectiongetConnection()Return a SQL connection to the database.StoreContextgetContext()Current persistence context.DBDictionarygetDBDictionary()Return the dictionary in use.JDBCFetchConfigurationgetFetchConfiguration()Return the current default fetch configuration.JDBCLockManagergetLockManager()If the lock manager in use is aJDBCLockManager, return it.java.sql.ConnectiongetNewConnection()Return a new SQL connection to the database.SQLFactorygetSQLFactory()Return the SQL factory for this runtime.voidloadSubclasses(ClassMapping mapping)Makes sure all subclasses of the given type are loaded in the JVM.IdnewDataStoreId(long id, ClassMapping mapping, boolean subs)Create a new datastore identity object from the given id value and mapping.
-
-
-
Method Detail
-
getContext
StoreContext getContext()
Current persistence context.
-
getConfiguration
JDBCConfiguration getConfiguration()
Return the configuration for this runtime.
-
getDBDictionary
DBDictionary getDBDictionary()
Return the dictionary in use.
-
getSQLFactory
SQLFactory getSQLFactory()
Return the SQL factory for this runtime.
-
getLockManager
JDBCLockManager getLockManager()
If the lock manager in use is aJDBCLockManager, return it.
-
getConnection
java.sql.Connection getConnection()
Return a SQL connection to the database. Theclosemethod should always be called on the connection to free any resources it is using. When appropriate, the close method is implemented as a no-op.
-
getNewConnection
java.sql.Connection getNewConnection()
Return a new SQL connection to the database. This is used when the current connection still has a open result set and a new database operation needs to be done. Theclosemethod should always be called on the connection to free any resources it is using. When appropriate, the close method is implemented as a no-op.
-
getFetchConfiguration
JDBCFetchConfiguration getFetchConfiguration()
Return the current default fetch configuration.
-
newDataStoreId
Id newDataStoreId(long id, ClassMapping mapping, boolean subs)
Create a new datastore identity object from the given id value and mapping.
-
find
java.lang.Object find(java.lang.Object oid, ValueMapping vm, JDBCFetchConfiguration fetch)Find the object with the given oid. Convenience method on top of the store's persistence context.- Parameters:
vm- the mapping holding this oid, or null if not applicable
-
loadSubclasses
void loadSubclasses(ClassMapping mapping)
Makes sure all subclasses of the given type are loaded in the JVM. This is usually done automatically.
-
-