Class JavaScriptFunctionApplyTargetSelector
java.lang.Object
com.ibm.wala.cast.js.ipa.callgraph.JavaScriptFunctionApplyTargetSelector
- All Implemented Interfaces:
MethodTargetSelector
We need to generate synthetic methods for Function.apply() in the target selector, so that the
AstMethod for Function_prototype_apply() in the prologue doesn't actually get used in the CGNodes
used for calls to Function.prototype.apply(). The generated dummy methods should never
actually be used except as a stub.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetCalleeTarget
(CGNode caller, CallSiteReference site, IClass receiver) Given a calling node, a call site and (optionally) a dispatch type, return the target method to be called.
-
Field Details
-
SYNTHETIC_APPLY_METHOD_PREFIX
- See Also:
-
-
Constructor Details
-
JavaScriptFunctionApplyTargetSelector
-
-
Method Details
-
getCalleeTarget
Description copied from interface:MethodTargetSelector
Given a calling node, a call site and (optionally) a dispatch type, return the target method to be called.- Specified by:
getCalleeTarget
in interfaceMethodTargetSelector
- Parameters:
caller
- the GCNode in the call graph containing the callsite
- the call site reference of the call sitereceiver
- the type of the target object or null- Returns:
- the method to be called.
-