|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.AbstractMap jwutil.collections.UnmodifiableMultiMap joeq.Compiler.Quad.CallGraph joeq.Compiler.Quad.LoadedCallGraph
public class LoadedCallGraph
A call graph that is loaded from a file.
Nested Class Summary | |
---|---|
static class |
LoadedCallGraph.SortedArraySetFactory
|
Nested classes/interfaces inherited from class joeq.Compiler.Quad.CallGraph |
---|
CallGraph.CallGraphCSNavigator, CallGraph.CallGraphMap, CallGraph.CallGraphMethodNavigator, CallGraph.CallSiteMap, CallGraph.CallTargetMap |
Nested classes/interfaces inherited from interface java.util.Map |
---|
Map.Entry<K,V> |
Field Summary | |
---|---|
protected boolean |
bcCallSites
|
static Comparator |
callsite_comparator
|
protected jwutil.collections.MultiMap |
callSites
|
protected jwutil.collections.InvertibleMultiMap |
edges
|
static Comparator |
member_comparator
|
protected Set |
methods
|
protected Set |
roots
|
static LoadedCallGraph.SortedArraySetFactory |
sortedArraySetFactory
|
static jwutil.collections.MapFactory |
treeMapFactory
|
static Comparator |
type_comparator
|
Fields inherited from class jwutil.collections.UnmodifiableMultiMap |
---|
DEFAULT_HISTOGRAM_SIZE |
Constructor Summary | |
---|---|
LoadedCallGraph(String filename)
|
Method Summary | |
---|---|
void |
add(jq_Method caller,
int bcIndex,
jq_Method callee)
|
Set |
entrySet()
|
Collection |
getAllCallSites()
Returns the collection of all call sites in the call graph. |
Collection |
getAllMethods()
Returns the collection of all methods in the call graph. |
Collection |
getCallees(jq_Method caller)
Returns the set of methods that are called by the given method. |
Collection |
getCallerMethods(jq_Method callee)
Returns the set of methods that can call the given method. |
Collection |
getCallers(jq_Method callee)
Returns the set of call sites that can call the given method. |
Collection |
getCallSites(jq_Method caller)
Returns the set of call sites in the given method. |
Collection |
getRoots()
Returns the collection of root methods for this call graph. |
Collection |
getTargetMethods(Object context,
ProgramLocation callSite)
Returns the possible target methods of the given call site under the given context. |
Set |
keySet()
|
static ProgramLocation |
mapCall(ProgramLocation callSite)
|
protected void |
read(DataInput in)
|
void |
setRoots(Collection roots)
Sets up the root methods to be the given set. |
static void |
write(CallGraph cg,
BufferedWriter out)
|
Methods inherited from class joeq.Compiler.Quad.CallGraph |
---|
calculateCallerRelation, calculateEdgeRelation, calculateReachableMethods, contains, findDepths, getCallees, getCallGraphMap, getCallSiteMap, getCallSiteNavigator, getCallSites, getCallSites0, getCallSites0, getCallSites1, getMethodNavigator, getNavigator, getTargetMethod, getTargetMethods, getValues, makeCallGraph, numberOfTargetMethods, numberOfTargetMethods, toString |
Methods inherited from class jwutil.collections.UnmodifiableMultiMap |
---|
add, addAll, addAll, clear, computeHistogram, computeHistogram, entrySetHelper, proxy, put, putAll, remove, remove, removeAll, retainAll |
Methods inherited from class java.util.AbstractMap |
---|
clone, containsKey, containsValue, equals, get, hashCode, isEmpty, size, values |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface jwutil.collections.MultiMap |
---|
get, size |
Methods inherited from interface java.util.Map |
---|
containsKey, containsValue, equals, hashCode, isEmpty, values |
Field Detail |
---|
public static Comparator type_comparator
public static Comparator member_comparator
public static Comparator callsite_comparator
public static final jwutil.collections.MapFactory treeMapFactory
public static final LoadedCallGraph.SortedArraySetFactory sortedArraySetFactory
protected Set methods
protected Set roots
protected jwutil.collections.MultiMap callSites
protected jwutil.collections.InvertibleMultiMap edges
protected boolean bcCallSites
Constructor Detail |
---|
public LoadedCallGraph(String filename) throws IOException
IOException
Method Detail |
---|
public static void write(CallGraph cg, BufferedWriter out) throws IOException
IOException
protected void read(DataInput in) throws IOException
IOException
public void add(jq_Method caller, int bcIndex, jq_Method callee)
public void setRoots(Collection roots)
CallGraph
setRoots
in class CallGraph
roots
- collection of root methodspublic Collection getRoots()
CallGraph
getRoots
in interface jwutil.graphs.Graph
getRoots
in class CallGraph
public Collection getTargetMethods(Object context, ProgramLocation callSite)
CallGraph
getTargetMethods
in class CallGraph
public Set entrySet()
entrySet
in interface Map
entrySet
in interface jwutil.collections.MultiMap
entrySet
in class CallGraph
public Collection getAllCallSites()
CallGraph
getAllCallSites
in class CallGraph
public Collection getAllMethods()
CallGraph
getAllMethods
in class CallGraph
public Collection getCallees(jq_Method caller)
CallGraph
getCallees
in class CallGraph
public Collection getCallers(jq_Method callee)
CallGraph
getCallers
in class CallGraph
public Collection getCallerMethods(jq_Method callee)
CallGraph
getCallerMethods
in class CallGraph
public Collection getCallSites(jq_Method caller)
CallGraph
getCallSites
in class CallGraph
public Set keySet()
keySet
in interface Map
keySet
in class AbstractMap
public static ProgramLocation mapCall(ProgramLocation callSite)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |