|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--net.walend.digraph.AbstractMatrixUEDigraph
|
+--net.walend.digraph.MutableMatrixUEDigraph
| Nested Class Summary |
| Nested classes inherited from class net.walend.digraph.AbstractMatrixUEDigraph |
AbstractMatrixUEDigraph.MatrixEdgeIterator, AbstractMatrixUEDigraph.NodeIterator |
| Field Summary | |
private static int |
DEFAULTSIZE
|
| Fields inherited from class net.walend.digraph.AbstractMatrixUEDigraph |
|
| Fields inherited from interface net.walend.digraph.UEDigraph |
EMPTY |
| Constructor Summary | |
MutableMatrixUEDigraph()
|
|
MutableMatrixUEDigraph(int nodeCapacity)
|
|
MutableMatrixUEDigraph(UEDigraph digraph)
|
|
| Method Summary | |
java.lang.Object |
addEdge(java.lang.Object fromNode,
java.lang.Object toNode,
java.lang.Object edge)
Return null if no existing edge is displaced by edge. |
boolean |
addNode(java.lang.Object node)
Return true if the node is added successfully, false if the digraph does not change. |
boolean |
addNodes(java.util.Set nodes)
Return true if adding the nodes changes the digraph. |
void |
clear()
Remove all nodes and edges from the UEDigraph |
void |
clearEdges()
Remove all the edges from the UEDigraph. |
boolean |
removeEdge(java.lang.Object edge)
Return true if this edge existed in the digraph, false if this operation doesn't change the digraph at all. |
java.lang.Object |
removeEdge(java.lang.Object fromNode,
java.lang.Object toNode)
Return the edge that connected fromNode to toNode, or null if no edge existed. |
boolean |
removeEdges(java.util.Set edges)
Return true if any edges were removed from the digraph. |
java.util.Set |
removeNode(java.lang.Object node)
Return the Set of orphaned edges that are removed with node |
java.util.Set |
removeNodes(java.util.Set nodes)
Return the Set of edges orphaned edges when these nodes are removed. |
java.util.Set |
removeUEDigraph(UEDigraph digraph)
Return a Set of edges orphaned when digraph is removed |
boolean |
retainEdges(java.util.Set edges)
Return true if this UEDigraph chages at all, false if not. |
java.util.Set |
retainNodes(java.util.Set nodes)
Return a Set of orphaned edges when the nodes are removed. |
| Methods inherited from class net.walend.digraph.AbstractMatrixUEDigraph |
containsEdge, containsEdge, containsEdge, containsEdges, containsNode, containsNodes, containsUEDigraph, countInboundEdges, countOutboundEdges, edgeCount, edgeIterator, edgeNodeIterator, getEdge, getEdges, getFromNode, getFromNodes, getInboundEdges, getNodes, getOutboundEdges, getPrincipleInterface, getToNode, getToNodes, growMatrix, intersectWithUEDigraph, isEdgeFree, isEmpty, nodeCount, nodeIterator, sameStateAs, sameUEDigraphAs, toString, unionUEDigraph |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface net.walend.digraph.UEDigraph |
containsEdge, containsEdge, containsEdges, containsUEDigraph, edgeIterator, getEdge, getEdges, getFromNode, getInboundEdges, getOutboundEdges, getToNode, intersectWithUEDigraph, sameUEDigraphAs, unionUEDigraph |
| Methods inherited from interface net.walend.digraph.Digraph |
containsEdge, containsNode, containsNodes, countInboundEdges, countOutboundEdges, edgeCount, edgeNodeIterator, getFromNodes, getNodes, getToNodes, isEdgeFree, isEmpty, nodeCount, nodeIterator |
| Methods inherited from interface net.walend.collection.HasState |
getPrincipleInterface, sameStateAs |
| Field Detail |
private static final int DEFAULTSIZE
| Constructor Detail |
public MutableMatrixUEDigraph()
public MutableMatrixUEDigraph(int nodeCapacity)
public MutableMatrixUEDigraph(UEDigraph digraph)
| Method Detail |
public boolean addNode(java.lang.Object node)
MutableUEDigraph
addNode in interface MutableUEDigraphaddNode in class AbstractMatrixUEDigraph
public java.lang.Object addEdge(java.lang.Object fromNode,
java.lang.Object toNode,
java.lang.Object edge)
throws NodeMissingException,
EdgeNotUniqueException
MutableUEDigraph
addEdge in interface MutableUEDigraphaddEdge in class AbstractMatrixUEDigraphNodeMissingException - if either node is not in the digraph.
EdgeNotUniqueException - if the edge is already in the digraph.
public java.util.Set removeNode(java.lang.Object node)
throws NodeMissingException
MutableUEDigraph
removeNode in interface MutableUEDigraphremoveNode in class AbstractMatrixUEDigraphNodeMissingException - if the node is not in the digraphpublic boolean removeEdge(java.lang.Object edge)
MutableUEDigraph
removeEdge in interface MutableUEDigraphremoveEdge in class AbstractMatrixUEDigraph
public java.lang.Object removeEdge(java.lang.Object fromNode,
java.lang.Object toNode)
throws NodeMissingException
MutableUEDigraph
removeEdge in interface MutableUEDigraphremoveEdge in class AbstractMatrixUEDigraphNodeMissingException - if either node is not in the digraphpublic boolean addNodes(java.util.Set nodes)
MutableUEDigraph
addNodes in interface MutableUEDigraphaddNodes in class AbstractMatrixUEDigraphpublic java.util.Set removeNodes(java.util.Set nodes)
MutableUEDigraph
removeNodes in interface MutableUEDigraphremoveNodes in class AbstractMatrixUEDigraphpublic boolean removeEdges(java.util.Set edges)
MutableUEDigraph
removeEdges in interface MutableUEDigraphremoveEdges in class AbstractMatrixUEDigraphpublic java.util.Set removeUEDigraph(UEDigraph digraph)
MutableUEDigraph
removeUEDigraph in interface MutableUEDigraphremoveUEDigraph in class AbstractMatrixUEDigraphpublic java.util.Set retainNodes(java.util.Set nodes)
MutableUEDigraph
retainNodes in interface MutableUEDigraphretainNodes in class AbstractMatrixUEDigraphpublic boolean retainEdges(java.util.Set edges)
MutableUEDigraph
retainEdges in interface MutableUEDigraphretainEdges in class AbstractMatrixUEDigraphpublic void clear()
MutableUEDigraph
clear in interface MutableUEDigraphclear in class AbstractMatrixUEDigraphpublic void clearEdges()
MutableUEDigraph
clearEdges in interface MutableUEDigraphclearEdges in class AbstractMatrixUEDigraph
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||