Package diva.graph.modular
Class BasicModularGraphModel.BasicEdgeModel
- java.lang.Object
-
- diva.graph.modular.BasicModularGraphModel.BasicEdgeModel
-
- All Implemented Interfaces:
EdgeModel
,MutableEdgeModel
- Enclosing class:
- BasicModularGraphModel
public static class BasicModularGraphModel.BasicEdgeModel extends java.lang.Object implements MutableEdgeModel
-
-
Constructor Summary
Constructors Constructor Description BasicEdgeModel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
acceptHead(java.lang.Object edge, java.lang.Object node)
Return true if the head of the given edge can be attached to the given node.boolean
acceptTail(java.lang.Object edge, java.lang.Object node)
Return true if the tail of the given edge can be attached to the given node.java.lang.Object
getHead(java.lang.Object edge)
Return the head node of the given edge.java.lang.Object
getTail(java.lang.Object edge)
Return the tail node of this edge.boolean
isDirected(java.lang.Object edge)
Return whether or not this edge is directed.void
setHead(java.lang.Object edge, java.lang.Object newHead)
Connect an edge to the given head node and notify listeners with an EDGE_HEAD_CHANGED event.void
setTail(java.lang.Object edge, java.lang.Object newTail)
Connect an edge to the given tail node and notify listeners with an EDGE_TAIL_CHANGED event.
-
-
-
Method Detail
-
acceptHead
public boolean acceptHead(java.lang.Object edge, java.lang.Object node)
Return true if the head of the given edge can be attached to the given node.- Specified by:
acceptHead
in interfaceMutableEdgeModel
-
acceptTail
public boolean acceptTail(java.lang.Object edge, java.lang.Object node)
Return true if the tail of the given edge can be attached to the given node.- Specified by:
acceptTail
in interfaceMutableEdgeModel
-
getHead
public java.lang.Object getHead(java.lang.Object edge)
Return the head node of the given edge.
-
getTail
public java.lang.Object getTail(java.lang.Object edge)
Return the tail node of this edge.
-
isDirected
public boolean isDirected(java.lang.Object edge)
Return whether or not this edge is directed.- Specified by:
isDirected
in interfaceEdgeModel
-
setHead
public void setHead(java.lang.Object edge, java.lang.Object newHead)
Connect an edge to the given head node and notify listeners with an EDGE_HEAD_CHANGED event.- Specified by:
setHead
in interfaceMutableEdgeModel
-
setTail
public void setTail(java.lang.Object edge, java.lang.Object newTail)
Connect an edge to the given tail node and notify listeners with an EDGE_TAIL_CHANGED event.- Specified by:
setTail
in interfaceMutableEdgeModel
-
-