|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object soot.jimple.toolkits.callgraph.CallGraph
public class CallGraph
Represents the edges in a call graph. This class is meant to act as only a container of edges; code for various call graph builders should be kept out of it, as well as most code for accessing the edges.
Field Summary | |
---|---|
protected Edge |
dummy
|
protected Set<Edge> |
edges
|
protected QueueReader<Edge> |
reader
|
protected Map<MethodOrMethodContext,Edge> |
srcMethodToEdge
|
protected Map<Unit,Edge> |
srcUnitToEdge
|
protected ChunkedQueue<Edge> |
stream
|
protected Map<MethodOrMethodContext,Edge> |
tgtToEdge
|
Constructor Summary | |
---|---|
CallGraph()
|
Method Summary | |
---|---|
boolean |
addEdge(Edge e)
Used to add an edge to the call graph. |
Iterator<Edge> |
edgesInto(MethodOrMethodContext m)
Returns an iterator over all edges that have m as their target method. |
Iterator<Edge> |
edgesOutOf(MethodOrMethodContext m)
Returns an iterator over all edges that have m as their source method. |
Iterator<Edge> |
edgesOutOf(Unit u)
Returns an iterator over all edges that have u as their source unit. |
Edge |
findEdge(Unit u,
SootMethod callee)
Find the specific call edge that is going out from the callsite u and the call target is callee. |
boolean |
isEntryMethod(SootMethod method)
Does this method have no incoming edge? |
QueueReader<Edge> |
listener()
Returns a QueueReader object containing all edges added so far, and which will be informed of any new edges that are later added to the graph. |
QueueReader<Edge> |
newListener()
Returns a QueueReader object which will contain ONLY NEW edges which will be added to the graph. |
boolean |
removeEdge(Edge e)
Removes the edge e from the call graph. |
int |
size()
Returns the number of edges in the call graph. |
Iterator<MethodOrMethodContext> |
sourceMethods()
Returns an iterator over all methods that are the sources of at least one edge. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Set<Edge> edges
protected ChunkedQueue<Edge> stream
protected QueueReader<Edge> reader
protected Map<MethodOrMethodContext,Edge> srcMethodToEdge
protected Map<Unit,Edge> srcUnitToEdge
protected Map<MethodOrMethodContext,Edge> tgtToEdge
protected Edge dummy
Constructor Detail |
---|
public CallGraph()
Method Detail |
---|
public boolean addEdge(Edge e)
public boolean removeEdge(Edge e)
public boolean isEntryMethod(SootMethod method)
method
-
public Edge findEdge(Unit u, SootMethod callee)
u
- callee
-
public Iterator<MethodOrMethodContext> sourceMethods()
public Iterator<Edge> edgesOutOf(Unit u)
public Iterator<Edge> edgesOutOf(MethodOrMethodContext m)
public Iterator<Edge> edgesInto(MethodOrMethodContext m)
public QueueReader<Edge> listener()
public QueueReader<Edge> newListener()
public String toString()
toString
in class Object
public int size()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |