com.ibm.wala.cast.js.ipa.callgraph
Class JSCallGraph.JSFakeRoot

java.lang.Object
  extended by com.ibm.wala.classLoader.SyntheticMethod
      extended by com.ibm.wala.ipa.callgraph.impl.AbstractRootMethod
          extended by com.ibm.wala.cast.ipa.callgraph.AstCallGraph.AstFakeRoot
              extended by com.ibm.wala.cast.ipa.callgraph.AstCallGraph.ScriptFakeRoot
                  extended by com.ibm.wala.cast.js.ipa.callgraph.JSCallGraph.JSFakeRoot
All Implemented Interfaces:
IMember, IMethod, ContextItem, IClassHierarchyDweller
Enclosing class:
JSCallGraph

public static class JSCallGraph.JSFakeRoot
extends AstCallGraph.ScriptFakeRoot


Field Summary
 
Fields inherited from class com.ibm.wala.ipa.callgraph.impl.AbstractRootMethod
cache, cha, insts, nextLocal, statements
 
Fields inherited from class com.ibm.wala.classLoader.SyntheticMethod
declaringClass, NO_STATEMENTS, resolvedMethod
 
Constructor Summary
JSCallGraph.JSFakeRoot(IClassHierarchy cha, AnalysisOptions options, AnalysisCache cache)
           
 
Method Summary
 SSANewInstruction addAllocation(TypeReference T)
          Add a New statement of the given type Side effect: adds call to default constructor of given type if one exists.
 SSAAbstractInvokeInstruction addDirectCall(int function, int[] params, CallSiteReference site)
           
 InducedCFG makeControlFlowGraph(SSAInstruction[] instructions)
          Create an InducedCFG from an instruction array.
 
Methods inherited from class com.ibm.wala.cast.ipa.callgraph.AstCallGraph.AstFakeRoot
addGlobalRead
 
Methods inherited from class com.ibm.wala.ipa.callgraph.impl.AbstractRootMethod
add1DArrayAllocation, addAllocationWithoutCtor, addCheckcast, addGetInstance, addGetStatic, addInvocation, addLocal, addPhi, addReturn, getInterpreter, getStatements, getValueNumberForByteConstant, getValueNumberForCharConstant, getValueNumberForIntConstant, makeIR
 
Methods inherited from class com.ibm.wala.classLoader.SyntheticMethod
equals, getBytecodeStream, getClassHierarchy, getDeclaredExceptions, getDeclaringClass, getDescriptor, getLineNumber, getLocalVariableName, getMaxLocals, getMaxStackHeight, getName, getNumberOfParameters, getParameterType, getPoison, getPoisonLevel, getReference, getReturnType, getSelector, getSignature, getStatements, hasExceptionHandler, hashCode, hasLocalVariableTable, hasPoison, isAbstract, isBridge, isClinit, isFactoryMethod, isFinal, isInit, isNative, isPrivate, isProtected, isPublic, isStatic, isSynchronized, isSynthetic, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JSCallGraph.JSFakeRoot

public JSCallGraph.JSFakeRoot(IClassHierarchy cha,
                              AnalysisOptions options,
                              AnalysisCache cache)
Method Detail

makeControlFlowGraph

public InducedCFG makeControlFlowGraph(SSAInstruction[] instructions)
Description copied from class: SyntheticMethod
Create an InducedCFG from an instruction array. NOTE: SIDE EFFECT!!! ... nulls out phi instructions in the instruction array!

Overrides:
makeControlFlowGraph in class AstCallGraph.AstFakeRoot

addAllocation

public SSANewInstruction addAllocation(TypeReference T)
Description copied from class: AbstractRootMethod
Add a New statement of the given type Side effect: adds call to default constructor of given type if one exists.

Overrides:
addAllocation in class AbstractRootMethod
Returns:
instruction added, or null

addDirectCall

public SSAAbstractInvokeInstruction addDirectCall(int function,
                                                  int[] params,
                                                  CallSiteReference site)
Specified by:
addDirectCall in class AstCallGraph.ScriptFakeRoot