liquibase.change
public class ConstraintsConfig extends java.lang.Object implements LiquibaseSerializable
LiquibaseSerializable.SerializationType
GENERIC_CHANGELOG_EXTENSION_NAMESPACE, GENERIC_SNAPSHOT_EXTENSION_NAMESPACE, STANDARD_CHANGELOG_NAMESPACE, STANDARD_SNAPSHOT_NAMESPACE
Constructor and Description |
---|
ConstraintsConfig() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getCheckConstraint()
Returns the check constraint to use on this column.
|
java.lang.String |
getForeignKeyName()
Returns the name to use for the columns foreign key constraint.
|
java.lang.String |
getPrimaryKeyName()
Returns the name to use for the primary key constraint.
|
java.lang.String |
getPrimaryKeyTablespace()
Returns the tablespace to use for the defined primary key.
|
java.lang.String |
getReferencedColumnNames() |
java.lang.String |
getReferencedTableName() |
java.lang.String |
getReferences()
Returns the "references" clause to use for the foreign key.
|
java.util.Set<java.lang.String> |
getSerializableFields() |
LiquibaseSerializable.SerializationType |
getSerializableFieldType(java.lang.String field) |
java.lang.Object |
getSerializableFieldValue(java.lang.String field) |
java.lang.String |
getSerializedObjectName() |
java.lang.String |
getSerializedObjectNamespace() |
java.lang.String |
getUniqueConstraintName()
Returns the name to use for the unique constraint.
|
java.lang.Boolean |
isDeferrable()
Returns if a foreign key defined for this column should deferrable.
|
java.lang.Boolean |
isDeleteCascade()
Returns if a foreign key defined for this column should cascade deletes.
|
java.lang.Boolean |
isInitiallyDeferred()
Returns if a foreign key defined for this column should be "initially deferred"c.
|
java.lang.Boolean |
isNullable()
Returns if the column should be nullable.
|
java.lang.Boolean |
isPrimaryKey()
Returns true if the column should be part of the primary key.
|
java.lang.Boolean |
isUnique()
Returns if the column is part of a unique constraint.
|
ConstraintsConfig |
setCheckConstraint(java.lang.String checkConstraint) |
ConstraintsConfig |
setDeferrable(java.lang.Boolean deferrable) |
ConstraintsConfig |
setDeferrable(java.lang.String deferrable)
Set the deferrable parameter based on the passed string.
|
ConstraintsConfig |
setDeleteCascade(java.lang.Boolean deleteCascade) |
ConstraintsConfig |
setDeleteCascade(java.lang.String deleteCascade)
Set the deleteCascade parameter based on the passed string.
|
ConstraintsConfig |
setForeignKeyName(java.lang.String foreignKeyName) |
ConstraintsConfig |
setInitiallyDeferred(java.lang.Boolean initiallyDeferred) |
ConstraintsConfig |
setInitiallyDeferred(java.lang.String initiallyDeferred)
Set the initiallyDeferred parameter based on the passed string.
|
ConstraintsConfig |
setNullable(java.lang.Boolean nullable) |
ConstraintsConfig |
setNullable(java.lang.String nullable)
Set the nullable parameter based on the passed string.
|
ConstraintsConfig |
setPrimaryKey(java.lang.Boolean primaryKey) |
ConstraintsConfig |
setPrimaryKey(java.lang.String primaryKey)
Set the primaryKey parameter based on the passed string.
|
ConstraintsConfig |
setPrimaryKeyName(java.lang.String primaryKeyName) |
ConstraintsConfig |
setPrimaryKeyTablespace(java.lang.String primaryKeyTablespace) |
void |
setReferencedColumnNames(java.lang.String referencedColumnNames) |
void |
setReferencedTableName(java.lang.String referencedTableName) |
ConstraintsConfig |
setReferences(java.lang.String references) |
ConstraintsConfig |
setUnique(java.lang.Boolean unique) |
ConstraintsConfig |
setUnique(java.lang.String unique)
Set the unique parameter based on the passed string.
|
ConstraintsConfig |
setUniqueConstraintName(java.lang.String uniqueConstraintName) |
public java.lang.Boolean isNullable()
public ConstraintsConfig setNullable(java.lang.Boolean nullable)
public ConstraintsConfig setNullable(java.lang.String nullable)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.Boolean isPrimaryKey()
public ConstraintsConfig setPrimaryKey(java.lang.Boolean primaryKey)
public ConstraintsConfig setPrimaryKey(java.lang.String primaryKey)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.String getPrimaryKeyName()
public ConstraintsConfig setPrimaryKeyName(java.lang.String primaryKeyName)
public java.lang.String getReferences()
public ConstraintsConfig setReferences(java.lang.String references)
public java.lang.Boolean isUnique()
public ConstraintsConfig setUnique(java.lang.Boolean unique)
public ConstraintsConfig setUnique(java.lang.String unique)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.String getUniqueConstraintName()
public ConstraintsConfig setUniqueConstraintName(java.lang.String uniqueConstraintName)
public java.lang.String getCheckConstraint()
public ConstraintsConfig setCheckConstraint(java.lang.String checkConstraint)
public java.lang.Boolean isDeleteCascade()
public ConstraintsConfig setDeleteCascade(java.lang.Boolean deleteCascade)
public ConstraintsConfig setDeleteCascade(java.lang.String deleteCascade)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.String getForeignKeyName()
public ConstraintsConfig setForeignKeyName(java.lang.String foreignKeyName)
public java.lang.Boolean isInitiallyDeferred()
public ConstraintsConfig setInitiallyDeferred(java.lang.Boolean initiallyDeferred)
public ConstraintsConfig setInitiallyDeferred(java.lang.String initiallyDeferred)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.Boolean isDeferrable()
public ConstraintsConfig setDeferrable(java.lang.Boolean deferrable)
public ConstraintsConfig setDeferrable(java.lang.String deferrable)
UnexpectedLiquibaseException
if a different value is passedpublic java.lang.String getPrimaryKeyTablespace()
public ConstraintsConfig setPrimaryKeyTablespace(java.lang.String primaryKeyTablespace)
public java.lang.String getReferencedTableName()
public void setReferencedTableName(java.lang.String referencedTableName)
public java.lang.String getReferencedColumnNames()
public void setReferencedColumnNames(java.lang.String referencedColumnNames)
public java.lang.String getSerializedObjectName()
getSerializedObjectName
in interface LiquibaseSerializable
public java.util.Set<java.lang.String> getSerializableFields()
getSerializableFields
in interface LiquibaseSerializable
public java.lang.Object getSerializableFieldValue(java.lang.String field)
getSerializableFieldValue
in interface LiquibaseSerializable
public LiquibaseSerializable.SerializationType getSerializableFieldType(java.lang.String field)
getSerializableFieldType
in interface LiquibaseSerializable
public java.lang.String getSerializedObjectNamespace()
getSerializedObjectNamespace
in interface LiquibaseSerializable