java.lang.Object
- All Implemented Interfaces:
ColumnDefinition,ContainerElementDefinition<TableDefinition>,Definition,PositionedDefinition,TypedElementDefinition<TableDefinition>
public class DefaultColumnDefinition
extends AbstractTypedElementDefinition<TableDefinition>
implements ColumnDefinition
A base implementation for column definitions.
- Author:
- Lukas Eder
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, boolean hidden, boolean readonly, String comment) DefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, boolean readonly, String comment) DefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, String comment) -
Method Summary
Modifier and TypeMethodDescriptionfinal List<ForeignKeyDefinition> All definitions of foreign keys that this column is part of.final List<UniqueKeyDefinition> getKeys()All definitions of unique and primary keys that this column is part of.final intThe object's 1-based position in the parent.final UniqueKeyDefinitionA definition for the primary key that this column is part of, ornullif this column is not part of a primary key.final List<UniqueKeyDefinition> All definitions of unique keys that this column is part of.final booleanisHidden()Whether this column is hidden.final booleanWhether this column is the table'sIDENTITYcolumn.final booleanWhether this column is readonly.final booleanWhether the object has been created "synthetically", i.e.Methods inherited from class org.jooq.meta.AbstractTypedElementDefinition
customType, getDataType, getDefinedType, getDomain, getType, getType, mapDefinedTypeMethods inherited from class org.jooq.meta.AbstractContainerElementDefinition
getContainer, getDefinitionPathMethods inherited from class org.jooq.meta.AbstractDefinition
create, create, equals, getCatalog, getComment, getConnection, getDatabase, getDialect, getInputName, getName, getOutputName, getOverload, getPackage, getPartiallyQualifiedNames, getQualifiedInputName, getQualifiedInputNamePart, getQualifiedName, getQualifiedNamePart, getQualifiedOutputName, getQualifiedOutputNamePart, getSchema, getSource, hashCode, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.jooq.meta.ContainerElementDefinition
getContainerMethods inherited from interface org.jooq.meta.Definition
getCatalog, getComment, getDatabase, getDefinitionPath, getInputName, getName, getOutputName, getOverload, getPackage, getPartiallyQualifiedNames, getQualifiedInputName, getQualifiedInputNamePart, getQualifiedName, getQualifiedNamePart, getQualifiedOutputName, getQualifiedOutputNamePart, getSchema, getSourceMethods inherited from interface org.jooq.meta.TypedElementDefinition
getDefinedType, getDomain, getType, getType
-
Constructor Details
-
DefaultColumnDefinition
public DefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, String comment) -
DefaultColumnDefinition
public DefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, boolean readonly, String comment) -
DefaultColumnDefinition
public DefaultColumnDefinition(TableDefinition table, String name, int position, DataTypeDefinition type, boolean identity, boolean hidden, boolean readonly, String comment)
-
-
Method Details
-
isSynthetic
public final boolean isSynthetic()Description copied from interface:DefinitionWhether the object has been created "synthetically", i.e. fromSyntheticObjectsType, rather than from the underlying meta data source.- Specified by:
isSyntheticin interfaceDefinition
-
getPosition
public final int getPosition()Description copied from interface:PositionedDefinitionThe object's 1-based position in the parent.[#17434] While in most RDBMS, this value is 1-based and a consecutive ordinal, there may be cases where a positional value is skipped, either by what's reported by the RDBMS's dictionary views, or because the definition is filtered by jOOQ-meta. Users shouldn't rely on the positions reflecting the actually generated column/attribute/etc. position.
- Specified by:
getPositionin interfacePositionedDefinition
-
getPrimaryKey
Description copied from interface:ColumnDefinitionA definition for the primary key that this column is part of, ornullif this column is not part of a primary key.- Specified by:
getPrimaryKeyin interfaceColumnDefinition
-
getUniqueKeys
Description copied from interface:ColumnDefinitionAll definitions of unique keys that this column is part of.- Specified by:
getUniqueKeysin interfaceColumnDefinition
-
getKeys
Description copied from interface:ColumnDefinitionAll definitions of unique and primary keys that this column is part of.- Specified by:
getKeysin interfaceColumnDefinition
-
getForeignKeys
Description copied from interface:ColumnDefinitionAll definitions of foreign keys that this column is part of.- Specified by:
getForeignKeysin interfaceColumnDefinition
-
isIdentity
public final boolean isIdentity()Description copied from interface:ColumnDefinitionWhether this column is the table'sIDENTITYcolumn.- Specified by:
isIdentityin interfaceColumnDefinition
-
isHidden
public final boolean isHidden()Description copied from interface:ColumnDefinitionWhether this column is hidden.- Specified by:
isHiddenin interfaceColumnDefinition
-
isReadonly
public final boolean isReadonly()Description copied from interface:ColumnDefinitionWhether this column is readonly.- Specified by:
isReadonlyin interfaceColumnDefinition
-