org.apache.ws.jaxme.sqls

Interface SQLFactory

public interface SQLFactory

A factory for generating SQL statements.

Author: Jochen Wiedmann

Nested Class Summary
static interfaceSQLFactory.Ident
Method Summary
SchemagetDefaultSchema()

Returns the Default schema.

IntegergetMaxColumnNameLength()

Returns the maximum length of a column name.

IntegergetMaxSchemaNameLength()

Returns the maximum length of a schema name.

IntegergetMaxTableNameLength()

Returns the maximum length of a table name.

ObjectFactorygetObjectFactory()

Returns the object factory being used.

SchemagetSchema(Schema.Name pName)

Returns the schema with the given name or null, if no such schema exists.

SchemagetSchema(String pName)

Returns the schema with the given name or null, if no such schema exists.

SchemagetSchema(Connection pConnection, Schema.Name pName)

Reads the schema named pName from the database.

SchemagetSchema(Connection pConnection, String pName)

Reads the schema named pName from the database.

IteratorgetSchemas()

Returns a list of all schemas.

TablegetTable(Connection pConnection, Schema.Name pSchema, Table.Name pTable)

Reads the table named pTable from the schema named pSchema in the database.

TablegetTable(Connection pConnection, String pSchema, String pTable)

Reads the table named pTable from the schema named pSchema in the database.

booleanisColumnNameCaseSensitive()

Returns whether column names are case sensitive or not.

booleanisSchemaNameCaseSensitive()

Returns whether schema names are case sensitive or not.

booleanisTableNameCaseSensitive()

Returns whether table names are case sensitive or not.

DeleteStatementnewDeleteStatement()

Creates a new DELETE statement.

InsertStatementnewInsertStatement()

Creates a new INSERT statement.

SchemanewSchema(String pName)

Creates a new Schema with the given name.

SchemanewSchema(Schema.Name pName)

Creates a new Schema with the given name.

SelectStatementnewSelectStatement()

Creates a new SELECT statement.

SQLGeneratornewSQLGenerator()

Creates a new SQLGenerator.

UpdateStatementnewUpdateStatement()

Creates a new UPDATE statement.

Method Detail

getDefaultSchema

public Schema getDefaultSchema()

Returns the Default schema. The default schema has the name null.

getMaxColumnNameLength

public Integer getMaxColumnNameLength()

Returns the maximum length of a column name.

Returns: 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.

Returns: 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.

Returns: The maximum length or null, if checks for valid table name length are disabled.

getObjectFactory

public ObjectFactory getObjectFactory()

Returns the object factory being used.

getSchema

public Schema getSchema(Schema.Name pName)

Returns the schema with the given name or null, if no such schema exists.

getSchema

public Schema getSchema(String pName)

Returns the schema with the given name or null, if no such schema exists.

getSchema

public Schema getSchema(Connection pConnection, Schema.Name pName)

Reads the schema named pName from the database.

getSchema

public Schema getSchema(Connection pConnection, String pName)

Reads the schema named pName from the database.

getSchemas

public Iterator getSchemas()

Returns a list of all schemas. The list includes the default schema, if getDefaultSchema was called at any time.

getTable

public Table getTable(Connection pConnection, Schema.Name pSchema, Table.Name pTable)

Reads the table named pTable from the schema named pSchema in the database.

getTable

public Table getTable(Connection pConnection, String pSchema, String pTable)

Reads the table named pTable from the schema named pSchema in the database.

isColumnNameCaseSensitive

public boolean isColumnNameCaseSensitive()

Returns whether column names are case sensitive or not. Defaults to false.

isSchemaNameCaseSensitive

public boolean isSchemaNameCaseSensitive()

Returns whether schema names are case sensitive or not. Defaults to false.

isTableNameCaseSensitive

public boolean isTableNameCaseSensitive()

Returns whether table names are case sensitive or not. Defaults to false.

newDeleteStatement

public DeleteStatement newDeleteStatement()

Creates a new DELETE statement.

newInsertStatement

public InsertStatement newInsertStatement()

Creates a new INSERT statement.

newSchema

public Schema newSchema(String pName)

Creates a new Schema with the given name.

newSchema

public Schema newSchema(Schema.Name pName)

Creates a new Schema with the given name.

newSelectStatement

public SelectStatement newSelectStatement()

Creates a new SELECT statement.

newSQLGenerator

public SQLGenerator newSQLGenerator()

Creates a new SQLGenerator.

newUpdateStatement

public UpdateStatement newUpdateStatement()

Creates a new UPDATE statement.