org.dbunit.util.search
Class Edge

java.lang.Object
  extended by org.dbunit.util.search.Edge
All Implemented Interfaces:
java.lang.Comparable, IEdge
Direct Known Subclasses:
FKRelationshipEdge, ForeignKeyRelationshipEdge

public class Edge
extends java.lang.Object
implements IEdge

Basic implementation of the IEdge interface.

Since:
2.2.0 (Aug 25, 2005)
Version:
$Revision: 826 $ $Date: 2008-10-05 19:42:03 +0200 (dom, 05 ott 2008) $
Author:
Felipe Leme (dbunit@felipeal.net), Last changed by: $Author: gommma $

Constructor Summary
Edge(java.lang.Comparable nodeFrom, java.lang.Comparable nodeTo)
           
 
Method Summary
 int compareTo(java.lang.Object o)
          Compares this edge to the given one using the getFrom() nodes first.
 boolean equals(java.lang.Object obj)
           
 java.lang.Object getFrom()
          Get the node this edge originates from.
 java.lang.Object getTo()
          Get the node this edge points to.
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Edge

public Edge(java.lang.Comparable nodeFrom,
            java.lang.Comparable nodeTo)
Parameters:
nodeFrom -
nodeTo -
Method Detail

getFrom

public java.lang.Object getFrom()
Description copied from interface: IEdge
Get the node this edge originates from.

Specified by:
getFrom in interface IEdge
Returns:
node this edge originates from.

getTo

public java.lang.Object getTo()
Description copied from interface: IEdge
Get the node this edge points to.

Specified by:
getTo in interface IEdge
Returns:
node this edge points to.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

compareTo

public int compareTo(java.lang.Object o)
Compares this edge to the given one using the getFrom() nodes first. If those are equal the getTo()} is used for comparison.

Specified by:
compareTo in interface java.lang.Comparable
See Also:
Comparable.compareTo(java.lang.Object)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2002-2010. All Rights Reserved.