org.d2rq.db.op
Class AssertUniqueKeyOp

java.lang.Object
  extended by org.d2rq.db.op.DatabaseOp.Wrapper
      extended by org.d2rq.db.op.AssertUniqueKeyOp
All Implemented Interfaces:
DatabaseOp

public class AssertUniqueKeyOp
extends DatabaseOp.Wrapper

Asserts that a certain combination of columns is unique in the wrapped DatabaseOp, even if no unique key is present on it. TODO: Remove this class and handle this as a modification to the underlying base table(s)'s definition(s) in RelationBuilder


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.d2rq.db.op.DatabaseOp
DatabaseOp.Wrapper
 
Field Summary
 
Fields inherited from interface org.d2rq.db.op.DatabaseOp
TRUE
 
Constructor Summary
AssertUniqueKeyOp(DatabaseOp wrapped, Key uniqueKey)
           
 
Method Summary
 void accept(OpVisitor visitor)
           
 boolean equals(Object o)
           
 Key getKey()
           
 Collection<Key> getUniqueKeys()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class org.d2rq.db.op.DatabaseOp.Wrapper
getColumns, getColumnType, getTableName, getWrapped, hasColumn, isNullable
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AssertUniqueKeyOp

public AssertUniqueKeyOp(DatabaseOp wrapped,
                         Key uniqueKey)
Method Detail

getKey

public Key getKey()

getUniqueKeys

public Collection<Key> getUniqueKeys()
Specified by:
getUniqueKeys in interface DatabaseOp
Overrides:
getUniqueKeys in class DatabaseOp.Wrapper

accept

public void accept(OpVisitor visitor)

toString

public String toString()
Overrides:
toString in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object o)
Overrides:
equals in class Object