public interface Database
| Modifier and Type | Interface and Description |
|---|---|
static interface |
Database.Filter
A filter type that can be used with
addFilter(Filter) |
| Modifier and Type | Method and Description |
|---|---|
void |
addFilter(Database.Filter filter)
[#3488] Add an additional filter to the database that is applied in
addition to include / exclude.
|
DSLContext |
create()
Create the factory for this database.
|
boolean |
dateAsTimestamp()
Whether DATE columns should be treated as TIMESTAMP columns.
|
boolean |
exists(Table<?> table)
Check for the existence of a table in the dictionary views.
|
<D extends Definition> |
filterExcludeInclude(List<D> definitions)
Filter a list of definitions according to the exclude / include / and filter settings of this database.
|
ArrayDefinition |
getArray(SchemaDefinition schema,
String name)
Get a ARRAY defined in this database by name.
|
ArrayDefinition |
getArray(SchemaDefinition schema,
String name,
boolean ignoreCase)
Get a ARRAY defined in this database by name.
|
List<ArrayDefinition> |
getArrays(SchemaDefinition schema)
The Arrays defined in this database.
|
List<CheckConstraintDefinition> |
getCheckConstraints(SchemaDefinition schema)
The check constraints contained in this database.
|
CustomType |
getConfiguredCustomType(String name)
Get a specific configured custom type by its name.
|
List<CustomType> |
getConfiguredCustomTypes()
Database objects matching any of these field names will be generated as
custom types.
|
List<EnumType> |
getConfiguredEnumTypes()
Database objects matching any of these field names will be generated as
enum types.
|
ForcedType |
getConfiguredForcedType(Definition definition)
Get the configured forced type object for any given
Definition,
or null if no ForcedType matches the definition. |
ForcedType |
getConfiguredForcedType(Definition definition,
DataTypeDefinition definedType)
Get the configured forced type object for any given
Definition,
or null if no ForcedType matches the definition. |
List<ForcedType> |
getConfiguredForcedTypes()
Database objects matching any of these field names will be generated as
forced types.
|
Connection |
getConnection()
The database connection.
|
SQLDialect |
getDialect()
Get the dialect for this database.
|
EnumDefinition |
getEnum(SchemaDefinition schema,
String name)
Get an enum UDT defined in this database by name.
|
EnumDefinition |
getEnum(SchemaDefinition schema,
String name,
boolean ignoreCase)
Get an enum UDT defined in this database by name.
|
List<EnumDefinition> |
getEnums(SchemaDefinition schema)
The enum UDTs defined in this database.
|
String[] |
getExcludes()
Database objects matching any of these regular expressions will not be
generated.
|
List<Database.Filter> |
getFilters()
[#3488] The filters that are applied in addition to include / exclude.
|
List<ForeignKeyDefinition> |
getForeignKeys(SchemaDefinition schema)
The foreign keys contained in this database.
|
List<IdentityDefinition> |
getIdentities(SchemaDefinition schema)
The identities contained in this database.
|
boolean |
getIncludeExcludeColumns()
Indicate whether include / exclude regular expression shall also match
database columns.
|
String[] |
getIncludes()
Only database objects matching any of these regular expressions will be
generated.
|
List<String> |
getInputSchemata()
The input schemata are the schemata that jooq-meta is reading data from.
|
String |
getOutputSchema(String inputSchema)
Deprecated.
- 2.0.5 - This will be implemented in each
Definition.getOutputName() |
String[] |
getOverridePrimaryKeys()
Unique keys matching these regular expressions will be considered as
primary keys in generated code.
|
List<PackageDefinition> |
getPackages(SchemaDefinition schema)
The packages contained in this database.
|
String[] |
getRecordTimestampFields()
Table columns matching these regular expressions will be considered as
record timestamp fields in generated code.
|
String[] |
getRecordVersionFields()
Table columns matching these regular expressions will be considered as
record version fields in generated code.
|
List<RegexFlag> |
getRegexFlags()
The regular expression flags that should be applied when using regular expressions.
|
Relations |
getRelations()
Retrieve the schema's primary key / foreign key relations.
|
List<RoutineDefinition> |
getRoutines(SchemaDefinition schema)
The stored routines (procedures and functions) contained in this
database.
|
SchemaDefinition |
getSchema(String name)
Get a schema defined in this database by name.
|
List<SchemaDefinition> |
getSchemata()
The schemata generated from this database.
|
SchemaVersionProvider |
getSchemaVersionProvider() |
List<SequenceDefinition> |
getSequences(SchemaDefinition schema)
The sequences contained in this database.
|
String[] |
getSyntheticPrimaryKeys()
Columns matching these regular expressions will be considered as members
of synthetic primary keys in generated code.
|
TableDefinition |
getTable(SchemaDefinition schema,
String name)
Get a table in this database by name.
|
TableDefinition |
getTable(SchemaDefinition schema,
String name,
boolean ignoreCase)
Get a table in this database by name.
|
List<TableDefinition> |
getTables(SchemaDefinition schema)
The tables contained in this database.
|
UDTDefinition |
getUDT(SchemaDefinition schema,
String name)
Get a UDT defined in this database by name.
|
UDTDefinition |
getUDT(SchemaDefinition schema,
String name,
boolean ignoreCase)
Get a UDT defined in this database by name.
|
List<UDTDefinition> |
getUDTs(SchemaDefinition schema)
The UDTs defined in this database.
|
List<UniqueKeyDefinition> |
getUniqueKeys(SchemaDefinition schema)
The unique keys contained in this database.
|
boolean |
ignoreProcedureReturnValues()
Whether this database should ignore procedure return values.
|
boolean |
includeRelations()
[#3559] Whether relations (i.e. constraints) should be included in this database.
|
boolean |
isArrayType(String dataType)
Check whether a type is an array type.
|
void |
setConfiguredCustomTypes(List<CustomType> types)
Database objects matching any of these field names will be generated as
custom types.
|
void |
setConfiguredEnumTypes(List<EnumType> types)
Database objects matching any of these field names will be generated as
enum types.
|
void |
setConfiguredForcedTypes(List<ForcedType> types)
Database objects matching any of these field names will be generated as
forced types.
|
void |
setConfiguredSchemata(List<Schema> schemata)
The input and output schemata.
|
void |
setConnection(Connection connection)
Initialise a connection to this database.
|
void |
setDateAsTimestamp(boolean dateAsTimestamp)
Whether DATE columns should be treated as TIMESTAMP columns.
|
void |
setExcludes(String[] excludes)
Database objects matching any of these regular expressions will not be
generated.
|
void |
setIgnoreProcedureReturnValues(boolean ignoreProcedureReturnValues)
Whether this database should ignore procedure return values.
|
void |
setIncludeExcludeColumns(boolean includeExcludeColumns)
Indicate whether include / exclude regular expression shall also match
database columns.
|
void |
setIncludeRelations(boolean includeRelations)
[#3559] Whether relations (i.e. constraints) should be included in this database.
|
void |
setIncludes(String[] includes)
Only database objects matching any of these regular expressions will be
generated.
|
void |
setOverridePrimaryKeys(String[] primaryKeys)
Unique keys matching these regular expressions will be considered as
primary keys in generated code.
|
void |
setProperties(Properties properties)
Database properties.
|
void |
setRecordTimestampFields(String[] recordTimestampFields)
Table columns matching these regular expressions will be considered as
record timestamp fields in generated code.
|
void |
setRecordVersionFields(String[] recordVersionFields)
Table columns matching these regular expressions will be considered as
record version fields in generated code.
|
void |
setRegexFlags(List<RegexFlag> regexFlags)
The regular expression flags that should be applied when using regular expressions.
|
void |
setSchemaVersionProvider(SchemaVersionProvider provider) |
void |
setSupportsUnsignedTypes(boolean supportsUnsignedTypes)
Whether this database supports unsigned types.
|
void |
setSyntheticPrimaryKeys(String[] primaryKeys)
Columns matching these regular expressions will be considered as members
of synthetic primary keys in generated code.
|
boolean |
supportsUnsignedTypes()
Whether this database supports unsigned types.
|
List<SchemaDefinition> getSchemata()
SchemaDefinition getSchema(String name)
Relations getRelations()
List<SequenceDefinition> getSequences(SchemaDefinition schema)
List<IdentityDefinition> getIdentities(SchemaDefinition schema)
List<UniqueKeyDefinition> getUniqueKeys(SchemaDefinition schema)
List<ForeignKeyDefinition> getForeignKeys(SchemaDefinition schema)
List<CheckConstraintDefinition> getCheckConstraints(SchemaDefinition schema)
List<TableDefinition> getTables(SchemaDefinition schema)
TableDefinition getTable(SchemaDefinition schema, String name)
TableDefinition getTable(SchemaDefinition schema, String name, boolean ignoreCase)
List<EnumDefinition> getEnums(SchemaDefinition schema)
EnumDefinition getEnum(SchemaDefinition schema, String name)
EnumDefinition getEnum(SchemaDefinition schema, String name, boolean ignoreCase)
List<UDTDefinition> getUDTs(SchemaDefinition schema)
UDTDefinition getUDT(SchemaDefinition schema, String name)
UDTDefinition getUDT(SchemaDefinition schema, String name, boolean ignoreCase)
List<ArrayDefinition> getArrays(SchemaDefinition schema)
ArrayDefinition getArray(SchemaDefinition schema, String name)
ArrayDefinition getArray(SchemaDefinition schema, String name, boolean ignoreCase)
List<RoutineDefinition> getRoutines(SchemaDefinition schema)
List<PackageDefinition> getPackages(SchemaDefinition schema)
void setConnection(Connection connection)
Connection getConnection()
List<String> getInputSchemata()
@Deprecated String getOutputSchema(String inputSchema)
Definition.getOutputName()void setConfiguredSchemata(List<Schema> schemata)
void setExcludes(String[] excludes)
String[] getExcludes()
void setIncludes(String[] includes)
String[] getIncludes()
void setIncludeExcludeColumns(boolean includeExcludeColumns)
boolean getIncludeExcludeColumns()
void addFilter(Database.Filter filter)
List<Database.Filter> getFilters()
<D extends Definition> List<D> filterExcludeInclude(List<D> definitions)
void setRegexFlags(List<RegexFlag> regexFlags)
List<RegexFlag> getRegexFlags()
void setRecordVersionFields(String[] recordVersionFields)
String[] getRecordVersionFields()
void setRecordTimestampFields(String[] recordTimestampFields)
String[] getRecordTimestampFields()
void setSyntheticPrimaryKeys(String[] primaryKeys)
String[] getSyntheticPrimaryKeys()
void setOverridePrimaryKeys(String[] primaryKeys)
String[] getOverridePrimaryKeys()
void setConfiguredCustomTypes(List<CustomType> types)
List<CustomType> getConfiguredCustomTypes()
CustomType getConfiguredCustomType(String name)
void setConfiguredEnumTypes(List<EnumType> types)
List<EnumType> getConfiguredEnumTypes()
void setConfiguredForcedTypes(List<ForcedType> types)
SchemaVersionProvider getSchemaVersionProvider()
void setSchemaVersionProvider(SchemaVersionProvider provider)
List<ForcedType> getConfiguredForcedTypes()
ForcedType getConfiguredForcedType(Definition definition)
Definition,
or null if no ForcedType matches the definition.ForcedType getConfiguredForcedType(Definition definition, DataTypeDefinition definedType)
Definition,
or null if no ForcedType matches the definition.SQLDialect getDialect()
DSLContext create()
boolean isArrayType(String dataType)
void setSupportsUnsignedTypes(boolean supportsUnsignedTypes)
boolean supportsUnsignedTypes()
void setIgnoreProcedureReturnValues(boolean ignoreProcedureReturnValues)
boolean ignoreProcedureReturnValues()
void setDateAsTimestamp(boolean dateAsTimestamp)
boolean dateAsTimestamp()
void setIncludeRelations(boolean includeRelations)
boolean includeRelations()
boolean exists(Table<?> table)
void setProperties(Properties properties)
Copyright © 2015. All Rights Reserved.