org.graffiti.graph
Class AbstractGraphElement

java.lang.Object
  extended by org.graffiti.attributes.AbstractAttributable
      extended by org.graffiti.graph.AbstractGraphElement
All Implemented Interfaces:
Attributable, GraphElement
Direct Known Subclasses:
AbstractEdge, AbstractNode

public abstract class AbstractGraphElement
extends AbstractAttributable
implements GraphElement

GraphElements are Attributables which know the graph they belong to. This class provides the functionality for accessing the graph.

See Also:
AbstractNode, AbstractEdge, Node, Edge

Constructor Summary
AbstractGraphElement()
          Constructs a new AbstrctGraphElement.
AbstractGraphElement(CollectionAttribute coll)
          Constructs a new AbstrctGraphElement.
AbstractGraphElement(Graph graph)
          Constructs a new AbstrctGraphElement.
AbstractGraphElement(Graph graph, CollectionAttribute coll)
          Constructs a new AbstrctGraphElement.
 
Method Summary
 Graph getGraph()
          Returns the Graph the AbstractGraphElement belongs to.
 ListenerManager getListenerManager()
          Returns the ListenerManager of the GraphElement.
 void remove()
          Remove element from graph.
 String toString()
           
 
Methods inherited from class org.graffiti.attributes.AbstractAttributable
addAttribute, addBoolean, addByte, addDouble, addFloat, addInteger, addLong, addShort, addString, changeBoolean, changeByte, changeDouble, changeFloat, changeInteger, changeLong, changeShort, changeString, containsAttribute, getAttribute, getAttributes, getBoolean, getByte, getDouble, getFloat, getInteger, getLong, getShort, getString, removeAttribute, setBoolean, setByte, setDouble, setFloat, setInteger, setLong, setShort, setString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.graffiti.attributes.Attributable
addAttribute, addBoolean, addByte, addDouble, addFloat, addInteger, addLong, addShort, addString, changeBoolean, changeByte, changeDouble, changeFloat, changeInteger, changeLong, changeShort, changeString, containsAttribute, getAttribute, getAttributes, getBoolean, getByte, getDouble, getFloat, getInteger, getLong, getShort, getString, removeAttribute, setBoolean, setByte, setDouble, setFloat, setInteger, setLong, setShort, setString
 

Constructor Detail

AbstractGraphElement

public AbstractGraphElement()
Constructs a new AbstrctGraphElement.


AbstractGraphElement

public AbstractGraphElement(CollectionAttribute coll)
Constructs a new AbstrctGraphElement.

Parameters:
coll - the CollectionAttribute of the new AbstractGraphElement instance.

AbstractGraphElement

public AbstractGraphElement(Graph graph,
                            CollectionAttribute coll)
Constructs a new AbstrctGraphElement. Sets the graph of the current AbstrctGraphElement.

Parameters:
graph - the graph the AbstrctGraphElement belongs to.
coll - the CollectionAttribute of the new AbstractGraphElement instance.

AbstractGraphElement

public AbstractGraphElement(Graph graph)
Constructs a new AbstrctGraphElement. Sets the graph of the current AbstrctGraphElement.

Parameters:
graph - the graph the AbstrctGraphElement belongs to.
Method Detail

getGraph

public Graph getGraph()
Returns the Graph the AbstractGraphElement belongs to.

Specified by:
getGraph in interface GraphElement
Returns:
the Graph the GraphElement belongs to.

remove

public void remove()
Remove element from graph.

Specified by:
remove in interface GraphElement

getListenerManager

public ListenerManager getListenerManager()
Returns the ListenerManager of the GraphElement.

Specified by:
getListenerManager in interface Attributable
Returns:
the ListenerManager of the GraphElement.

toString

public String toString()
Overrides:
toString in class Object


Generated at 2012-05-30 11:00:14 PM CEST