Default implementation of an SQLFactory.
getMaxColumnNameLength
public Integer getMaxColumnNameLength()
Returns the maximum length of a column name.
- getMaxColumnNameLength in interface SQLFactory
- The maximum length or null, if checks for valid column name
length are disabled.
getMaxSchemaNameLength
public Integer getMaxSchemaNameLength()
Returns the maximum length of a schema name.
- getMaxSchemaNameLength in interface SQLFactory
- The maximum length or null, if checks for valid schema name
length are disabled.
getMaxTableNameLength
public Integer getMaxTableNameLength()
Returns the maximum length of a table name.
- getMaxTableNameLength in interface SQLFactory
- The maximum length or null, if checks for valid table name
length are disabled.
getSchema
public Schema getSchema(Connection pConn,
String pName)
throws SQLException
Reads the schema named pName
from the database.
- getSchema in interface SQLFactory
getSchema
public Schema getSchema(String pName)
Returns the schema with the given name or null, if no such
schema exists.
- getSchema in interface SQLFactory
getTable
public Table getTable(Connection pConnection,
String pSchema,
String pTable)
throws SQLException
Reads the table named pTable
from the schema
named pSchema
in the database.
- getTable in interface SQLFactory
getTable
public Table getTable(Connection pConnection,
Schema.Name pSchema,
Table.Name pTable)
throws SQLException
Reads the table named pTable
from the schema
named pSchema
in the database.
- getTable in interface SQLFactory
isColumnNameCaseSensitive
public boolean isColumnNameCaseSensitive()
Returns whether column names are case sensitive or not. Defaults to
false.
- isColumnNameCaseSensitive in interface SQLFactory
isSchemaNameCaseSensitive
public boolean isSchemaNameCaseSensitive()
Returns whether schema names are case sensitive or not. Defaults to
false.
- isSchemaNameCaseSensitive in interface SQLFactory
isTableNameCaseSensitive
public boolean isTableNameCaseSensitive()
Returns whether table names are case sensitive or not. Defaults to
false.
- isTableNameCaseSensitive in interface SQLFactory
newIdent
public SQLFactory.Ident newIdent(String pName)
Converths the given string into an SQL identifier.
readColumn
protected Column readColumn(Table pTable,
String pColumnName,
int pDataType,
String pTypeName,
long pColumnSize,
int pDecimalDigits,
int pNullable)
readForeignKeys
protected ForeignKey[] readForeignKeys(DatabaseMetaData pData,
org.apache.ws.jaxme.sqls.impl.SQLFactoryImpl.JDBCTable pTable,
org.apache.ws.jaxme.sqls.impl.SQLFactoryImpl.JDBCTable[] pTables)
throws SQLException
readPrimaryKey
protected Index readPrimaryKey(DatabaseMetaData pData,
org.apache.ws.jaxme.sqls.impl.SQLFactoryImpl.JDBCTable pTable)
throws SQLException
readTable
protected Table readTable(DatabaseMetaData pData,
Schema pSchema,
org.apache.ws.jaxme.sqls.impl.SQLFactoryImpl.JDBCTable pTable)
throws SQLException
readTables
protected org.apache.ws.jaxme.sqls.impl.SQLFactoryImpl.JDBCTable[] readTables(DatabaseMetaData pData,
Schema.Name pSchema,
Table.Name pTable)
throws SQLException
setColumnNameCaseSensitive
public void setColumnNameCaseSensitive(boolean pColumnNameCaseSensitive)
Sets whether column names are case sensitive or not. Defaults
to false.
setMaxColumnNameLength
public void setMaxColumnNameLength(Integer pMaxLength)
Sets the maximum length of a column name.
pMaxLength
- The maximum length or null to disable checks for
valid column name length.
setMaxSchemaNameLength
public void setMaxSchemaNameLength(Integer pMaxLength)
Sets the maximum length of a schema name.
pMaxLength
- The maximum length or null to disable checks for
valid schema name length.
setMaxTableNameLength
public void setMaxTableNameLength(Integer pMaxLength)
Sets the maximum length of a table name.
pMaxLength
- The maximum length or null to disable checks for
valid table name length.
setObjectFactory
protected void setObjectFactory(ObjectFactory pFactory)
setSchemaNameCaseSensitive
public void setSchemaNameCaseSensitive(boolean pSchemaNameCaseSensitive)
Sets whether schema names are case sensitive or not. Defaults
to false.
setTableNameCaseSensitive
public void setTableNameCaseSensitive(boolean pTableNameCaseSensitive)
Sets whether table names are case sensitive or not. Defaults
to false.