public class SQLDatabaseTypeExtensionPoint extends AbstractThreadSafeComponentExtensionPoint<SQLDatabaseType>
SQLDatabaseType
Modifier and Type | Field and Description |
---|---|
static String |
ROLE
Avalon Role
|
_cocoonManager, _context, _manager
Constructor and Description |
---|
SQLDatabaseTypeExtensionPoint() |
Modifier and Type | Method and Description |
---|---|
Map<Object,I18nizableText> |
getSQLDatabaseTypes()
Get the SQL database types with their label
|
void |
initializeExtensions()
Finalize the initialization of the extensions.
This method is called after all addExtension() calls.This is the last step before the actual startup of the application. |
String |
languageEscapeTableName(String dbtype,
String tableNameToEscape)
Some db systems requires the table names to be escaped
|
String |
languageLimitQuery(String dbtype,
String queryToLimit,
String limit,
String offset)
Add a limit/offset element to the given query
|
addComponent, addExtension, contextualize, dispose, getExtension, getExtensionsIds, hasExtension, initialize, service
getLogger, setLogger
public SQLDatabaseTypeExtensionPoint()
public void initializeExtensions() throws Exception
ExtensionPoint
addExtension()
calls.initializeExtensions
in interface ExtensionPoint<SQLDatabaseType>
initializeExtensions
in class AbstractThreadSafeComponentExtensionPoint<SQLDatabaseType>
Exception
- if something wrong occurspublic Map<Object,I18nizableText> getSQLDatabaseTypes()
public String languageEscapeTableName(String dbtype, String tableNameToEscape)
dbtype
- The identifier of the db type usedtableNameToEscape
- The non-null table namepublic String languageLimitQuery(String dbtype, String queryToLimit, String limit, String offset)
dbtype
- The identifier of the db type usedqueryToLimit
- The sql query that will be amendedlimit
- The max number of the results to returnoffset
- The initial offset of the results to return