soot.jimple.toolkits.callgraph
Class Edge

java.lang.Object
  extended bysoot.jimple.toolkits.callgraph.Edge

public final class Edge
extends java.lang.Object

Represents a single edge in a call graph.

Author:
Ondrej Lhotak

Field Summary
static int CLINIT
          Implicit call to static initializer.
static int EXIT
          Implicit call to Thread.exit().
static int FINALIZE
          Implicit call to non-trivial finalizer from constructor.
static int INTERFACE
          Due to explicit invokeinterface instruction.
static int INVALID
           
static java.lang.String[] kinds
           
static int NEWINSTANCE
          Implicit call to constructor from java.lang.Class.newInstance().
static int PRIVILEGED
          Implicit call to run() through AccessController.doPrivileged().
static int SPECIAL
          Due to explicit invokespecial instruction.
static int STATIC
          Due to explicit invokestatic instruction.
static int THREAD
          Implicit call to Thread.run() due to Thread.start() call.
static int VIRTUAL
          Due to explicit invokevirtual instruction.
 
Constructor Summary
Edge(MethodOrMethodContext src, Stmt srcUnit, MethodOrMethodContext tgt)
           
Edge(MethodOrMethodContext src, Unit srcUnit, MethodOrMethodContext tgt, int type)
           
 
Method Summary
 boolean equals(java.lang.Object other)
           
 MethodOrMethodContext getSrc()
           
 MethodOrMethodContext getTgt()
           
 int hashCode()
           
static int ieToKind(InvokeExpr ie)
           
 boolean isClinit()
          Returns true if the call is to static initializer.
 boolean isExplicit()
          Returns true if the call is due to an explicit invoke statement.
 boolean isInstance()
          Returns true if the call is due to an explicit instance invoke statement.
 boolean isStatic()
          Returns true if the call is due to an explicit static invoke statement.
 int kind()
           
static java.lang.String kindToString(int kind)
           
 boolean passesParameters()
           
 SootMethod src()
           
 java.lang.Object srcCtxt()
           
 Stmt srcStmt()
           
 Unit srcUnit()
           
 SootMethod tgt()
           
 java.lang.Object tgtCtxt()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

INVALID

public static final int INVALID
See Also:
Constant Field Values

STATIC

public static final int STATIC
Due to explicit invokestatic instruction.

See Also:
Constant Field Values

VIRTUAL

public static final int VIRTUAL
Due to explicit invokevirtual instruction.

See Also:
Constant Field Values

INTERFACE

public static final int INTERFACE
Due to explicit invokeinterface instruction.

See Also:
Constant Field Values

SPECIAL

public static final int SPECIAL
Due to explicit invokespecial instruction.

See Also:
Constant Field Values

CLINIT

public static final int CLINIT
Implicit call to static initializer.

See Also:
Constant Field Values

THREAD

public static final int THREAD
Implicit call to Thread.run() due to Thread.start() call.

See Also:
Constant Field Values

EXIT

public static final int EXIT
Implicit call to Thread.exit().

See Also:
Constant Field Values

FINALIZE

public static final int FINALIZE
Implicit call to non-trivial finalizer from constructor.

See Also:
Constant Field Values

PRIVILEGED

public static final int PRIVILEGED
Implicit call to run() through AccessController.doPrivileged().

See Also:
Constant Field Values

NEWINSTANCE

public static final int NEWINSTANCE
Implicit call to constructor from java.lang.Class.newInstance().

See Also:
Constant Field Values

kinds

public static final java.lang.String[] kinds
Constructor Detail

Edge

public Edge(MethodOrMethodContext src,
            Unit srcUnit,
            MethodOrMethodContext tgt,
            int type)

Edge

public Edge(MethodOrMethodContext src,
            Stmt srcUnit,
            MethodOrMethodContext tgt)
Method Detail

src

public SootMethod src()

srcCtxt

public java.lang.Object srcCtxt()

getSrc

public MethodOrMethodContext getSrc()

srcUnit

public Unit srcUnit()

srcStmt

public Stmt srcStmt()

tgt

public SootMethod tgt()

tgtCtxt

public java.lang.Object tgtCtxt()

getTgt

public MethodOrMethodContext getTgt()

kind

public int kind()

ieToKind

public static int ieToKind(InvokeExpr ie)

isExplicit

public boolean isExplicit()
Returns true if the call is due to an explicit invoke statement.


isInstance

public boolean isInstance()
Returns true if the call is due to an explicit instance invoke statement.


isClinit

public boolean isClinit()
Returns true if the call is to static initializer.


isStatic

public boolean isStatic()
Returns true if the call is due to an explicit static invoke statement.


passesParameters

public boolean passesParameters()

hashCode

public int hashCode()

equals

public boolean equals(java.lang.Object other)

kindToString

public static java.lang.String kindToString(int kind)

toString

public java.lang.String toString()