T - The class that the code will be operating on.ID - The class of the ID column associated with the class. The T class
does not require an ID field. The class needs an ID parameter
however so you can use Void or Object to satisfy the compiler.public abstract class GeoPackageDao<T,ID> extends BaseDaoImpl<T,ID>
Dao.CreateOrUpdateStatus, Dao.DaoObserver| Modifier and Type | Field and Description |
|---|---|
protected GeoPackageCoreConnection |
db
Database connection
|
connectionSource, constructor, databaseType, dataClass, lastIterator, objectFactory, statementExecutor, tableConfig, tableInfo| Constructor and Description |
|---|
GeoPackageDao(ConnectionSource connectionSource,
Class<T> dataClass)
Constructor, required by ORMLite
|
| Modifier and Type | Method and Description |
|---|---|
<D extends GeoPackageDao<O,?>,O> |
createDao(Class<O> clazz)
Create a GeoPackage DAO
|
static <D extends GeoPackageDao<O,?>,O> |
createDao(GeoPackageCoreConnection db,
Class<O> clazz)
Create a GeoPackage DAO
|
static <D extends GeoPackageDao<O,?>,O> |
createDao(GeoPackageCoreConnection db,
DatabaseTableConfig<O> tableConfig)
Create a GeoPackage DAO
|
void |
dropTable(String table)
Drop the table
|
GeoPackageCoreConnection |
getDatabase()
Get the database
|
boolean |
isTable()
Check if the DAO is backed by a table
|
boolean |
isTableExists()
Check if the DAO is backed by a table or a view
|
boolean |
isTableOrView()
Check if the DAO is backed by a table or a view
|
boolean |
isView()
Check if the DAO is backed by a view
|
void |
setDatabase(GeoPackageCoreConnection db)
Set the database
|
boolean |
tableExists(String tableName)
Check if the table exists
|
boolean |
tableOrViewExists(String name)
Check if a table or view exists with the name
|
void |
verifyExists()
Verify the DAO is backed by a table or view
|
boolean |
viewExists(String viewName)
Check if the view exists
|
assignEmptyForeignCollection, callBatchTasks, checkForInitialized, clearAllInternalObjectCaches, clearObjectCache, closeableIterator, closeLastIterator, commit, countOf, countOf, create, create, createIfNotExists, createObjectInstance, createOrUpdate, delete, delete, delete, deleteBuilder, deleteById, deleteIds, endThreadConnection, executeRaw, executeRawNoArgs, extractId, findForeignFieldType, getConnectionSource, getDataClass, getEmptyForeignCollection, getObjectCache, getRawRowMapper, getSelectStarRowMapper, getTableConfig, getTableInfo, getTableName, getWrappedIterable, getWrappedIterable, idExists, initialize, isAutoCommit, isUpdatable, iterator, iterator, iterator, iterator, mapSelectStarRow, notifyChanges, objectsEqual, objectToString, query, queryBuilder, queryForAll, queryForEq, queryForFieldValues, queryForFieldValuesArgs, queryForFirst, queryForId, queryForMatching, queryForMatchingArgs, queryForSameId, queryRaw, queryRaw, queryRaw, queryRaw, queryRaw, queryRawValue, refresh, registerObserver, rollBack, setAutoCommit, setConnectionSource, setObjectCache, setObjectCache, setObjectFactory, setTableConfig, startThreadConnection, unregisterObserver, update, update, updateBuilder, updateId, updateRawclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorprotected GeoPackageCoreConnection db
public GeoPackageDao(ConnectionSource connectionSource, Class<T> dataClass) throws SQLException
connectionSource - connection sourcedataClass - data classSQLException - upon failurepublic boolean isTableExists()
throws SQLException
isTableExists in interface Dao<T,ID>isTableExists in class BaseDaoImpl<T,ID>SQLExceptionpublic boolean isTableOrView()
public boolean isTable()
public boolean isView()
public void verifyExists()
public void setDatabase(GeoPackageCoreConnection db)
db - database connectionpublic GeoPackageCoreConnection getDatabase()
public void dropTable(String table)
table - table namepublic boolean tableExists(String tableName)
tableName - table namepublic boolean viewExists(String viewName)
viewName - view namepublic boolean tableOrViewExists(String name)
name - table or view namepublic <D extends GeoPackageDao<O,?>,O> D createDao(Class<O> clazz)
D - DAO typeO - DAO object typeclazz - DAO class typepublic static <D extends GeoPackageDao<O,?>,O> D createDao(GeoPackageCoreConnection db, Class<O> clazz)
D - DAO typeO - DAO object typedb - database connectionclazz - DAO class typepublic static <D extends GeoPackageDao<O,?>,O> D createDao(GeoPackageCoreConnection db, DatabaseTableConfig<O> tableConfig) throws SQLException
D - DAO typeO - DAO object typedb - database connectiontableConfig - table configSQLException - upon errorCopyright © 2021 National Geospatial-Intelligence Agency. All rights reserved.