Class SootUtil


  • public class SootUtil
    extends Object
    Utility methods for dealing with Soot.
    Author:
    manu_s
    • Constructor Detail

      • SootUtil

        public SootUtil()
    • Method Detail

      • isRetNode

        public static boolean isRetNode​(VarNode node)
        Parameters:
        node -
        Returns:
        true if node represents the return value of a method; false otherwise
      • isParamNode

        public static boolean isParamNode​(VarNode node)
      • isThisNode

        public static boolean isThisNode​(VarNode node)
        Parameters:
        node -
        Returns:
        true if node represents the this parameter of a method; false otherwise
      • inLibrary

        public static boolean inLibrary​(String className)
        Parameters:
        outerType -
        Returns:
      • inLibrary

        public static boolean inLibrary​(RefType type)
      • isStringNode

        public static boolean isStringNode​(VarNode node)
      • isExceptionNode

        public static boolean isExceptionNode​(VarNode node)
        Parameters:
        node -
        Returns:
      • isThreadGlobal

        public static boolean isThreadGlobal​(VarNode node)
      • isThreadStartMethod

        public static boolean isThreadStartMethod​(SootMethod method)
      • hasRecursiveField

        public static boolean hasRecursiveField​(SootClass sootClass)
      • dumpVarNodeInfo

        public static void dumpVarNodeInfo​(PAG pag)
      • noRefTypeParameters

        public static boolean noRefTypeParameters​(SootMethod method)
      • getMainMethod

        public static SootMethod getMainMethod()
      • isResolvableCall

        public static boolean isResolvableCall​(SootMethod invokedMethod)
      • createDirIfNotExist

        public static String createDirIfNotExist​(String dirName)
      • getFreeLiveMemory

        public static long getFreeLiveMemory()
      • printNodeNumberMapping

        public static void printNodeNumberMapping​(String fileName,
                                                  PAG pag)
      • getAmbiguousMethodByName

        public static SootMethod getAmbiguousMethodByName​(String methodName)
      • fakeSignature

        public static String fakeSignature​(String qualifiedName)
        This method should be removed soon.
        Parameters:
        qualifiedName -
        Returns:
      • getClassName

        public static String getClassName​(String qualifiedName)
      • getMethodName

        public static String getMethodName​(String qualifiedName)
      • isNewInstanceMethod

        public static boolean isNewInstanceMethod​(SootMethod method)