Package soot

Class RefType

    • Field Detail

      • sootClass

        protected volatile SootClass sootClass
    • Method Detail

      • v

        public static RefType v​(String className)
        Create a RefType for a class.
        Parameters:
        className - The name of the class used to parameterize the created RefType.
        Returns:
        a RefType for the given class name.
      • v

        public static RefType v​(SootClass c)
        Create a RefType for a class.
        Parameters:
        c - A SootClass for which to create a RefType.
        Returns:
        a RefType for the given SootClass..
      • getClassName

        public String getClassName()
      • getSootClass

        public SootClass getSootClass()
        Get the SootClass object corresponding to this RefType.
        Returns:
        the corresponding SootClass
      • hasSootClass

        public boolean hasSootClass()
      • setClassName

        public void setClassName​(String className)
      • setSootClass

        public void setSootClass​(SootClass sootClass)
        Set the SootClass object corresponding to this RefType.
        Parameters:
        sootClass - The SootClass corresponding to this RefType.
      • equals

        public boolean equals​(Object t)
        Two RefTypes are considered equal if they are parameterized by the same class name String.
        Overrides:
        equals in class Object
        Parameters:
        t - an object to test for equality. @ return true if t is a RefType parameterized by the same name as this.
      • toString

        public String toString()
        Description copied from class: Type
        Returns a textual representation of this type.
        Specified by:
        toString in class Type
      • toQuotedString

        public String toQuotedString()
        Returns a textual representation, quoted as needed, of this type for serialization, e.g. to .jimple format
        Overrides:
        toQuotedString in class Type
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • apply

        public void apply​(Switch sw)
        Description copied from class: Type
        Method required for use of Switchable.
        Specified by:
        apply in interface Switchable
        Overrides:
        apply in class Type
      • merge

        public Type merge​(Type other,
                          Scene cm)
        Returns the least common superclass of this type and other.
        Overrides:
        merge in class Type
      • getArrayElementType

        public Type getArrayElementType()
        Description copied from class: RefLikeType
        If I have a variable x of declared type t, what is a good declared type for the expression ((Object[]) x)[i]? The getArrayElementType() method in RefLikeType was introduced even later to answer this question for all classes implementing RefLikeType. If t is an array, then the answer is the same as getElementType(). But t could also be Object, Serializable, or Cloneable, which can all hold any array, so then the answer is Object.
        Specified by:
        getArrayElementType in class RefLikeType
      • getAnySubType

        public AnySubType getAnySubType()
      • setAnySubType

        public void setAnySubType​(AnySubType anySubType)
      • isAllowedInFinalCode

        public boolean isAllowedInFinalCode()
        Description copied from class: Type
        Returns true if this type is allowed to appear in final (clean) Jimple code.
        Overrides:
        isAllowedInFinalCode in class Type
        Returns: