Package com.ibm.wala.util.graph.impl
Class SlowNumberedNodeManager<T>
- java.lang.Object
-
- com.ibm.wala.util.graph.impl.SlowNumberedNodeManager<T>
-
- All Implemented Interfaces:
NodeManager<T>
,NumberedNodeManager<T>
,Serializable
,Iterable<T>
public class SlowNumberedNodeManager<T> extends Object implements NumberedNodeManager<T>, Serializable
An object which manages node numbers via a mapping.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SlowNumberedNodeManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addNode(T n)
add a node to this graphboolean
containsNode(T N)
int
getMaxNumber()
T
getNode(int number)
int
getNumber(T obj)
int
getNumberOfNodes()
Iterator<T>
iterateNodes(IntSet s)
Iterator<T>
iterator()
void
removeNode(T n)
remove a node from this graphString
toString()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
getNumber
public int getNumber(T obj)
- Specified by:
getNumber
in interfaceNumberedNodeManager<T>
-
getNode
public T getNode(int number)
- Specified by:
getNode
in interfaceNumberedNodeManager<T>
-
getMaxNumber
public int getMaxNumber()
- Specified by:
getMaxNumber
in interfaceNumberedNodeManager<T>
-
getNumberOfNodes
public int getNumberOfNodes()
- Specified by:
getNumberOfNodes
in interfaceNodeManager<T>
- Returns:
- the number of nodes in this graph
-
addNode
public void addNode(T n)
Description copied from interface:NodeManager
add a node to this graph- Specified by:
addNode
in interfaceNodeManager<T>
-
removeNode
public void removeNode(T n)
Description copied from interface:NodeManager
remove a node from this graph- Specified by:
removeNode
in interfaceNodeManager<T>
-
containsNode
public boolean containsNode(T N)
- Specified by:
containsNode
in interfaceNodeManager<T>
- Returns:
- true iff the graph contains the specified node
-
iterateNodes
public Iterator<T> iterateNodes(IntSet s)
- Specified by:
iterateNodes
in interfaceNumberedNodeManager<T>
- Returns:
- iterator of nodes with the numbers in set s
-
-