net.sourceforge.combean.util
Class GenericWrapper

Package class diagram package GenericWrapper
java.lang.Object
  extended by net.sourceforge.combean.util.GenericWrapper
Direct Known Subclasses:
ObjectAsEdge, ObjectAsNode

public class GenericWrapper
extends Object

A generic base class for wrapping an object. Provides access to the inner object and an equality function based on the inner object.


Constructor Summary
GenericWrapper(Object o)
          constructor.
 
Method Summary
 boolean equals(Object o)
           
 Object getInnerObject()
          Access to inner object.
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GenericWrapper

public GenericWrapper(Object o)
constructor.

Parameters:
o - the object to wrap
Method Detail

getInnerObject

public final Object getInnerObject()
Access to inner object.

Returns:
the inner object

equals

public boolean equals(Object o)
Overrides:
equals in class Object
See Also:
Object.equals(Object)

hashCode

public int hashCode()
Overrides:
hashCode in class Object
See Also:
Object.hashCode()

toString

public String toString()
Overrides:
toString in class Object