Package com.tonic.analysis.cpg.node
Class CallSiteNode
- java.lang.Object
-
- com.tonic.analysis.cpg.node.CPGNode
-
- com.tonic.analysis.cpg.node.CallSiteNode
-
public class CallSiteNode extends CPGNode
CPG node wrapping an invoke instruction, exposing its resolved target signature.
-
-
Constructor Summary
Constructors Constructor Description CallSiteNode(long id, InvokeInstruction invoke)Creates a node for an invoke instruction.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetArgumentCount()StringgetFullTarget()InvokeInstructiongetInvoke()InvokeTypegetInvokeType()StringgetLabel()StringgetTargetDescriptor()StringgetTargetName()StringgetTargetOwner()<T> TgetUnderlying()booleanisInterface()booleanisSpecial()booleanisStatic()booleanisVirtual()StringtoString()-
Methods inherited from class com.tonic.analysis.cpg.node.CPGNode
addIncomingEdge, addOutgoingEdge, astChildren, astParent, cfgPredecessors, cfgSuccessors, controlDependencies, dataDependencies, equals, getEdges, getId, getIncomingEdges, getIncomingEdges, getInDegree, getNodeType, getOutDegree, getOutgoingEdges, getOutgoingEdges, getProperties, getProperty, getTaintLabel, hashCode, hasProperty, isTainted, removeIncomingEdge, removeOutgoingEdge, removeProperty, setProperty, setTainted, setTaintLabel
-
-
-
-
Constructor Detail
-
CallSiteNode
public CallSiteNode(long id, InvokeInstruction invoke)Creates a node for an invoke instruction.- Parameters:
id- the unique node idinvoke- the wrapped invoke instruction
-
-
Method Detail
-
getInvoke
public InvokeInstruction getInvoke()
- Returns:
- the invoke
-
getTargetOwner
public String getTargetOwner()
- Returns:
- the target owner
-
getTargetName
public String getTargetName()
- Returns:
- the target name
-
getTargetDescriptor
public String getTargetDescriptor()
- Returns:
- the target descriptor
-
getLabel
public String getLabel()
-
getUnderlying
public <T> T getUnderlying()
- Specified by:
getUnderlyingin classCPGNode- Type Parameters:
T- the expected underlying type- Returns:
- the wrapped IR or analysis object
-
getFullTarget
public String getFullTarget()
- Returns:
- the target as owner.name plus descriptor
-
getInvokeType
public InvokeType getInvokeType()
- Returns:
- the invoke dispatch kind
-
isStatic
public boolean isStatic()
- Returns:
- whether this is an invokestatic call
-
isVirtual
public boolean isVirtual()
- Returns:
- whether this is an invokevirtual call
-
isInterface
public boolean isInterface()
- Returns:
- whether this is an invokeinterface call
-
isSpecial
public boolean isSpecial()
- Returns:
- whether this is an invokespecial call
-
getArgumentCount
public int getArgumentCount()
- Returns:
- the number of call arguments
-
-