public abstract class BaseDB
extends java.lang.Object
implements com.liferay.portal.kernel.dao.db.DB
| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
ALTER_COLUMN_NAME |
protected static java.lang.String |
ALTER_COLUMN_TYPE |
protected static java.lang.String |
ALTER_TABLE_NAME |
protected static java.lang.String |
CREATE_TABLE |
protected static java.lang.String |
DROP_INDEX |
protected static java.lang.String |
DROP_PRIMARY_KEY |
protected static java.lang.String[] |
RENAME_TABLE_TEMPLATE |
protected static java.lang.String[] |
REWORD_TEMPLATE |
protected static java.lang.String[] |
TEMPLATE |
| Modifier | Constructor and Description |
|---|---|
protected |
BaseDB(com.liferay.portal.kernel.dao.db.DBType dbType,
int majorVersion,
int minorVersion) |
| Modifier and Type | Method and Description |
|---|---|
void |
addIndexes(java.sql.Connection con,
java.lang.String indexesSQL,
java.util.Set<java.lang.String> validIndexNames) |
protected java.lang.String[] |
buildColumnNameTokens(java.lang.String line) |
protected java.lang.String[] |
buildColumnTypeTokens(java.lang.String line) |
void |
buildCreateFile(java.lang.String sqlDir,
java.lang.String databaseName)
Deprecated.
As of Athanasius (7.3.x), with no direct replacement
|
void |
buildCreateFile(java.lang.String sqlDir,
java.lang.String databaseName,
int population)
Deprecated.
As of Athanasius (7.3.x), with no direct replacement
|
abstract java.lang.String |
buildSQL(java.lang.String template) |
void |
buildSQLFile(java.lang.String sqlDir,
java.lang.String fileName)
Deprecated.
As of Athanasius (7.3.x), with no direct replacement
|
protected java.lang.String[] |
buildTableNameTokens(java.lang.String line) |
protected java.util.Set<java.lang.String> |
dropIndexes(java.sql.Connection con,
java.lang.String tablesSQL,
java.lang.String indexesSQL,
java.util.List<com.liferay.portal.kernel.dao.db.Index> indexes) |
com.liferay.portal.kernel.dao.db.DBType |
getDBType() |
java.util.List<com.liferay.portal.kernel.dao.db.Index> |
getIndexes(java.sql.Connection connection) |
java.sql.ResultSet |
getIndexResultSet(java.sql.Connection connection,
java.lang.String tableName) |
int |
getMajorVersion() |
int |
getMinorVersion() |
java.sql.ResultSet |
getPrimaryKeysResultSet(java.sql.Connection connection,
java.lang.String tableName) |
java.lang.Integer |
getSQLType(java.lang.String templateType) |
protected abstract int[] |
getSQLTypes() |
protected abstract java.lang.String[] |
getTemplate() |
java.lang.String |
getTemplateBlob() |
java.lang.String |
getTemplateFalse() |
java.lang.String |
getTemplateTrue() |
java.lang.String |
getVersionString() |
long |
increment()
Deprecated.
As of Athanasius (7.3.x), replaced by
CounterLocalServiceUtil.increment() |
long |
increment(java.lang.String name)
Deprecated.
As of Athanasius (7.3.x), replaced by
CounterLocalServiceUtil.increment(String) |
long |
increment(java.lang.String name,
int size)
Deprecated.
As of Athanasius (7.3.x), replaced by
CounterLocalServiceUtil.increment(String, int) |
boolean |
isSupportsAlterColumnName() |
boolean |
isSupportsAlterColumnType() |
boolean |
isSupportsInlineDistinct() |
boolean |
isSupportsQueryingAfterException() |
boolean |
isSupportsScrollableResults() |
boolean |
isSupportsStringCaseSensitiveQuery() |
boolean |
isSupportsUpdateWithInnerJoin() |
protected java.lang.String |
limitColumnLength(java.lang.String column,
int length) |
protected java.lang.String |
replaceTemplate(java.lang.String template) |
protected abstract java.lang.String |
reword(java.lang.String data) |
void |
runSQL(java.sql.Connection con,
java.lang.String sql) |
void |
runSQL(java.sql.Connection con,
java.lang.String[] sqls) |
void |
runSQL(java.lang.String sql) |
void |
runSQL(java.lang.String[] sqls) |
void |
runSQLTemplate(java.lang.String path)
Deprecated.
As of Athanasius (7.3.x), replaced by
DBProcess#runSQLTemplate(String) |
void |
runSQLTemplate(java.lang.String path,
boolean failOnError)
Deprecated.
As of Athanasius (7.3.x), replaced by
DBProcess#runSQLTemplate(String, boolean) |
void |
runSQLTemplateString(java.sql.Connection connection,
java.lang.String template,
boolean failOnError) |
void |
runSQLTemplateString(java.sql.Connection connection,
java.lang.String template,
boolean evaluate,
boolean failOnError)
Deprecated.
As of Athanasius (7.3.x), replaced by
runSQLTemplateString(Connection, String, boolean) |
void |
runSQLTemplateString(java.lang.String template,
boolean failOnError) |
void |
runSQLTemplateString(java.lang.String template,
boolean evaluate,
boolean failOnError)
Deprecated.
As of Athanasius (7.3.x), replaced by
runSQLTemplateString(String, boolean) |
void |
setSupportsStringCaseSensitiveQuery(boolean supportsStringCaseSensitiveQuery) |
void |
updateIndexes(java.sql.Connection con,
java.lang.String tablesSQL,
java.lang.String indexesSQL,
boolean dropIndexes) |
protected static final java.lang.String ALTER_COLUMN_NAME
protected static final java.lang.String ALTER_COLUMN_TYPE
protected static final java.lang.String ALTER_TABLE_NAME
protected static final java.lang.String CREATE_TABLE
protected static final java.lang.String DROP_INDEX
protected static final java.lang.String DROP_PRIMARY_KEY
protected static final java.lang.String[] RENAME_TABLE_TEMPLATE
protected static final java.lang.String[] REWORD_TEMPLATE
protected static final java.lang.String[] TEMPLATE
protected BaseDB(com.liferay.portal.kernel.dao.db.DBType dbType,
int majorVersion,
int minorVersion)
public void addIndexes(java.sql.Connection con,
java.lang.String indexesSQL,
java.util.Set<java.lang.String> validIndexNames)
throws java.io.IOException
addIndexes in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOException@Deprecated
public void buildCreateFile(java.lang.String sqlDir,
java.lang.String databaseName)
throws java.io.IOException
buildCreateFile in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOException@Deprecated
public void buildCreateFile(java.lang.String sqlDir,
java.lang.String databaseName,
int population)
throws java.io.IOException
buildCreateFile in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionpublic abstract java.lang.String buildSQL(java.lang.String template)
throws java.io.IOException,
java.sql.SQLException
buildSQL in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLException@Deprecated
public void buildSQLFile(java.lang.String sqlDir,
java.lang.String fileName)
throws java.io.IOException
buildSQLFile in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionpublic com.liferay.portal.kernel.dao.db.DBType getDBType()
getDBType in interface com.liferay.portal.kernel.dao.db.DBpublic java.util.List<com.liferay.portal.kernel.dao.db.Index> getIndexes(java.sql.Connection connection)
throws java.sql.SQLException
getIndexes in interface com.liferay.portal.kernel.dao.db.DBjava.sql.SQLExceptionpublic java.sql.ResultSet getIndexResultSet(java.sql.Connection connection,
java.lang.String tableName)
throws java.sql.SQLException
getIndexResultSet in interface com.liferay.portal.kernel.dao.db.DBjava.sql.SQLExceptionpublic int getMajorVersion()
getMajorVersion in interface com.liferay.portal.kernel.dao.db.DBpublic int getMinorVersion()
getMinorVersion in interface com.liferay.portal.kernel.dao.db.DBpublic java.sql.ResultSet getPrimaryKeysResultSet(java.sql.Connection connection,
java.lang.String tableName)
throws java.sql.SQLException
getPrimaryKeysResultSet in interface com.liferay.portal.kernel.dao.db.DBjava.sql.SQLExceptionpublic java.lang.Integer getSQLType(java.lang.String templateType)
getSQLType in interface com.liferay.portal.kernel.dao.db.DBpublic java.lang.String getTemplateBlob()
getTemplateBlob in interface com.liferay.portal.kernel.dao.db.DBpublic java.lang.String getTemplateFalse()
getTemplateFalse in interface com.liferay.portal.kernel.dao.db.DBpublic java.lang.String getTemplateTrue()
getTemplateTrue in interface com.liferay.portal.kernel.dao.db.DBpublic java.lang.String getVersionString()
getVersionString in interface com.liferay.portal.kernel.dao.db.DB@Deprecated public long increment()
CounterLocalServiceUtil.increment()increment in interface com.liferay.portal.kernel.dao.db.DB@Deprecated public long increment(java.lang.String name)
CounterLocalServiceUtil.increment(String)increment in interface com.liferay.portal.kernel.dao.db.DB@Deprecated
public long increment(java.lang.String name,
int size)
CounterLocalServiceUtil.increment(String, int)increment in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsAlterColumnName()
isSupportsAlterColumnName in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsAlterColumnType()
isSupportsAlterColumnType in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsInlineDistinct()
isSupportsInlineDistinct in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsQueryingAfterException()
isSupportsQueryingAfterException in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsScrollableResults()
isSupportsScrollableResults in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsStringCaseSensitiveQuery()
isSupportsStringCaseSensitiveQuery in interface com.liferay.portal.kernel.dao.db.DBpublic boolean isSupportsUpdateWithInnerJoin()
isSupportsUpdateWithInnerJoin in interface com.liferay.portal.kernel.dao.db.DBpublic void runSQL(java.sql.Connection con,
java.lang.String sql)
throws java.io.IOException,
java.sql.SQLException
runSQL in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLExceptionpublic void runSQL(java.sql.Connection con,
java.lang.String[] sqls)
throws java.io.IOException,
java.sql.SQLException
runSQL in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLExceptionpublic void runSQL(java.lang.String sql)
throws java.io.IOException,
java.sql.SQLException
runSQL in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLExceptionpublic void runSQL(java.lang.String[] sqls)
throws java.io.IOException,
java.sql.SQLException
runSQL in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLException@Deprecated
public void runSQLTemplate(java.lang.String path)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
DBProcess#runSQLTemplate(String)runSQLTemplate in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLException@Deprecated
public void runSQLTemplate(java.lang.String path,
boolean failOnError)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
DBProcess#runSQLTemplate(String, boolean)runSQLTemplate in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLExceptionpublic void runSQLTemplateString(java.sql.Connection connection,
java.lang.String template,
boolean failOnError)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
runSQLTemplateString in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLException@Deprecated
public void runSQLTemplateString(java.sql.Connection connection,
java.lang.String template,
boolean evaluate,
boolean failOnError)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
runSQLTemplateString(Connection, String, boolean)runSQLTemplateString in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLExceptionpublic void runSQLTemplateString(java.lang.String template,
boolean failOnError)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
runSQLTemplateString in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLException@Deprecated
public void runSQLTemplateString(java.lang.String template,
boolean evaluate,
boolean failOnError)
throws java.io.IOException,
javax.naming.NamingException,
java.sql.SQLException
runSQLTemplateString(String, boolean)runSQLTemplateString in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjavax.naming.NamingExceptionjava.sql.SQLExceptionpublic void setSupportsStringCaseSensitiveQuery(boolean supportsStringCaseSensitiveQuery)
setSupportsStringCaseSensitiveQuery in interface com.liferay.portal.kernel.dao.db.DBpublic void updateIndexes(java.sql.Connection con,
java.lang.String tablesSQL,
java.lang.String indexesSQL,
boolean dropIndexes)
throws java.io.IOException,
java.sql.SQLException
updateIndexes in interface com.liferay.portal.kernel.dao.db.DBjava.io.IOExceptionjava.sql.SQLExceptionprotected java.lang.String[] buildColumnNameTokens(java.lang.String line)
protected java.lang.String[] buildColumnTypeTokens(java.lang.String line)
protected java.lang.String[] buildTableNameTokens(java.lang.String line)
protected java.util.Set<java.lang.String> dropIndexes(java.sql.Connection con,
java.lang.String tablesSQL,
java.lang.String indexesSQL,
java.util.List<com.liferay.portal.kernel.dao.db.Index> indexes)
throws java.io.IOException,
java.sql.SQLException
java.io.IOExceptionjava.sql.SQLExceptionprotected abstract int[] getSQLTypes()
protected abstract java.lang.String[] getTemplate()
protected java.lang.String limitColumnLength(java.lang.String column,
int length)
protected java.lang.String replaceTemplate(java.lang.String template)
protected abstract java.lang.String reword(java.lang.String data)
throws java.io.IOException,
java.sql.SQLException
java.io.IOExceptionjava.sql.SQLException