org.hibernate.metamodel.relational
Class UniqueKey

java.lang.Object
  extended by org.hibernate.metamodel.relational.AbstractConstraint
      extended by org.hibernate.metamodel.relational.UniqueKey
All Implemented Interfaces:
Constraint, Exportable

public class UniqueKey
extends AbstractConstraint
implements Constraint

Models a SQL INDEX defined as UNIQUE


Constructor Summary
protected UniqueKey(Table table, String name)
           
 
Method Summary
 String getExportIdentifier()
          Get a unique identifier to make sure we are not exporting the same database structure multiple times.
 boolean isCreationVetoed(Dialect dialect)
           
 String sqlConstraintStringInAlterTable(Dialect dialect)
           
 String sqlConstraintStringInCreateTable(Dialect dialect)
           
 
Methods inherited from class org.hibernate.metamodel.relational.AbstractConstraint
addColumn, getColumns, getColumnSpan, getName, getTable, internalAddColumn, internalColumnAccess, sqlCreateStrings, sqlDropStrings
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.hibernate.metamodel.relational.Constraint
getColumns, getName, getTable
 
Methods inherited from interface org.hibernate.metamodel.relational.Exportable
sqlCreateStrings, sqlDropStrings
 

Constructor Detail

UniqueKey

protected UniqueKey(Table table,
                    String name)
Method Detail

getExportIdentifier

public String getExportIdentifier()
Description copied from interface: Exportable
Get a unique identifier to make sure we are not exporting the same database structure multiple times.

Specified by:
getExportIdentifier in interface Exportable
Returns:
The exporting identifier.

isCreationVetoed

public boolean isCreationVetoed(Dialect dialect)
Overrides:
isCreationVetoed in class AbstractConstraint

sqlConstraintStringInCreateTable

public String sqlConstraintStringInCreateTable(Dialect dialect)

sqlConstraintStringInAlterTable

public String sqlConstraintStringInAlterTable(Dialect dialect)
Specified by:
sqlConstraintStringInAlterTable in class AbstractConstraint


Copyright © 2001-2012 Red Hat, Inc. All Rights Reserved.