Package org.apache.openjpa.jdbc.schema
Class Constraint
- java.lang.Object
-
- org.apache.openjpa.jdbc.schema.Constraint
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
ForeignKey,LocalConstraint
public abstract class Constraint extends java.lang.ObjectA table constraint. This class is closely aligned with the constraint information available fromDatabaseMetaData.- Author:
- Abe White
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidderef()booleanequals(java.lang.Object o)DBIdentifiergetColumnIdentifier()java.lang.StringgetColumnName()Deprecated.DBIdentifiergetFullIdentifier()java.lang.StringgetFullName()Deprecated.DBIdentifiergetIdentifier()java.lang.StringgetName()Deprecated.QualifiedDBIdentifiergetQualifiedPath()intgetRefCount()DBIdentifiergetSchemaIdentifier()java.lang.StringgetSchemaName()Deprecated.TablegetTable()Return the table of this constraint.DBIdentifiergetTableIdentifier()java.lang.StringgetTableName()Deprecated.inthashCode()booleanisDeferred()Return true if this is a deferred constraint.abstract booleanisLogical()Return whether this constraint is a logical constraint only; i.e.voidref()voidsetColumnIdentifier(DBIdentifier name)voidsetColumnName(java.lang.String name)Deprecated.voidsetDeferred(boolean deferred)Make this constrain deferred.voidsetIdentifier(DBIdentifier name)voidsetName(java.lang.String name)Deprecated.voidsetSchemaIdentifier(DBIdentifier schema)voidsetSchemaName(java.lang.String schema)Deprecated.voidsetTableIdentifier(DBIdentifier name)voidsetTableName(java.lang.String name)Deprecated.java.lang.StringtoString()
-
-
-
Method Detail
-
getTable
public Table getTable()
Return the table of this constraint.
-
getTableName
@Deprecated public java.lang.String getTableName()
Deprecated.Return the column's table name.
-
getTableIdentifier
public DBIdentifier getTableIdentifier()
-
setTableName
@Deprecated public void setTableName(java.lang.String name)
Deprecated.Set the column's table name. You can only call this method on columns whose table object is not set.
-
setTableIdentifier
public void setTableIdentifier(DBIdentifier name)
-
getSchemaName
@Deprecated public java.lang.String getSchemaName()
Deprecated.Return the column table's schema name.
-
getSchemaIdentifier
public DBIdentifier getSchemaIdentifier()
-
setSchemaName
@Deprecated public void setSchemaName(java.lang.String schema)
Deprecated.Set the column table's schema name. You can only call this method on columns whose table object is not set.
-
setSchemaIdentifier
public void setSchemaIdentifier(DBIdentifier schema)
-
getColumnName
@Deprecated public java.lang.String getColumnName()
Deprecated.Return the column's name.
-
getColumnIdentifier
public DBIdentifier getColumnIdentifier()
-
setColumnName
@Deprecated public void setColumnName(java.lang.String name)
Deprecated.Set the column's name. You can only call this method on columns whose table object is not set.
-
setColumnIdentifier
public void setColumnIdentifier(DBIdentifier name)
-
getName
@Deprecated public java.lang.String getName()
Deprecated.Return the name of the constraint.
-
getIdentifier
public DBIdentifier getIdentifier()
-
setName
@Deprecated public void setName(java.lang.String name)
Deprecated.Set the name of the constraint. This method cannot be called if the constraint already belongs to a table.
-
setIdentifier
public void setIdentifier(DBIdentifier name)
-
getFullName
@Deprecated public java.lang.String getFullName()
Deprecated.Return the full name of the constraint.
-
getQualifiedPath
public QualifiedDBIdentifier getQualifiedPath()
-
getFullIdentifier
public DBIdentifier getFullIdentifier()
-
isLogical
public abstract boolean isLogical()
Return whether this constraint is a logical constraint only; i.e. if it does not exist in the database.
-
isDeferred
public boolean isDeferred()
Return true if this is a deferred constraint.
-
setDeferred
public void setDeferred(boolean deferred)
Make this constrain deferred.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
getRefCount
public int getRefCount()
-
ref
public void ref()
-
deref
public void deref()
-
-