com.gmail.thejcwk.semantics.topicmaps
Class Relationship

java.lang.Object
  extended by com.gmail.thejcwk.semantics.topicmaps.Relationship

public class Relationship
extends java.lang.Object

Encapsulates a relationship between Elements.

Author:
Jan Kroeze

Constructor Summary
Relationship()
           
Relationship(Element aFrom, Element aTo)
           
 
Method Summary
 boolean equals(java.lang.Object rhs)
           
 Element getFrom()
           
 Element getTo()
           
 void setFrom(Element from)
           
 void setTo(Element to)
           
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Relationship

public Relationship()

Relationship

public Relationship(Element aFrom,
                    Element aTo)
Method Detail

equals

public boolean equals(java.lang.Object rhs)
Overrides:
equals in class java.lang.Object
Returns:
True if the from and to elements of both Relationships are equal as defined by their equal methods. False if rhs isn't a relationship.

getFrom

public Element getFrom()
Returns:
null if no from element has been set

setFrom

public void setFrom(Element from)

getTo

public Element getTo()
Returns:
null if no to element has been set

setTo

public void setTo(Element to)