public abstract class AbstractRelationship extends BaseObject implements Relationship
Constructor and Description |
---|
AbstractRelationship() |
Modifier and Type | Method and Description |
---|---|
protected static Table |
checkSameTable(List<Column> columns) |
protected boolean |
classEquals(BaseObject obj)
Override this method if the equals method should support different
subtypes.
|
int |
compareTo(Relationship that) |
boolean |
containsColumnPair(Column pkColumn,
Column fkColumn)
Determines whether this relationship contains a specific pair of columns
|
protected void |
decorateIdentity(List<Object> identifiers)
Subclasses should implement this method and add all fields to the list
that are to be included in equals(...) and hashCode() evaluation
|
Table |
getForeignTable()
Gets the table of the foreign key column(s).
|
Table |
getPrimaryTable()
Gets the table of the primary key column(s).
|
String |
toString() |
equals, hashCode
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getForeignColumns, getPrimaryColumns
public Table getForeignTable()
Relationship
getForeignTable
in interface Relationship
public Table getPrimaryTable()
Relationship
getPrimaryTable
in interface Relationship
public String toString()
toString
in class BaseObject
public int compareTo(Relationship that)
compareTo
in interface Comparable<Relationship>
protected final void decorateIdentity(List<Object> identifiers)
BaseObject
decorateIdentity
in class BaseObject
protected final boolean classEquals(BaseObject obj)
BaseObject
obj instanceof Number
and make sure that the decorateIdentity(...) method will always return a
comparable list of identity-objects.classEquals
in class BaseObject
public boolean containsColumnPair(Column pkColumn, Column fkColumn)
Relationship
containsColumnPair
in interface Relationship
pkColumn
- primary key columnfkColumn
- foreign key columnCopyright © 2007–2017 The Apache Software Foundation. All rights reserved.