Package soot
Class ModuleRefType
- java.lang.Object
-
- soot.Type
-
- soot.RefLikeType
-
- soot.RefType
-
- soot.ModuleRefType
-
- All Implemented Interfaces:
Serializable,Comparable<RefType>,Numberable,Switchable
public class ModuleRefType extends RefType
A class that models Java's reference types. RefTypes are parameterized by a class name. Two RefType are equal iff they are parameterized by the same class name as a String. Extends RefType in order to deal with Java 9 modules.- Author:
- Andreas Dann
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedModuleRefType(String className, String moduleName)ModuleRefType(Singletons.Global g)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TypegetArrayElementType()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.StringgetModuleName()SootClassgetSootClass()Get the SootClass object corresponding to this RefType.Typemerge(Type other, Scene cm)Returns the least common superclass of this type and other.static RefTypev(String className)static RefTypev(String className, com.google.common.base.Optional<String> moduleName)-
Methods inherited from class soot.RefType
apply, compareTo, equals, getAnySubType, getClassName, hashCode, hasSootClass, isAllowedInFinalCode, setAnySubType, setClassName, setSootClass, toQuotedString, toString, v, v
-
Methods inherited from class soot.Type
getArrayType, getDefaultFinalType, getEscapedName, getNumber, makeArrayType, setArrayType, setNumber, toMachineType
-
-
-
-
Constructor Detail
-
ModuleRefType
public ModuleRefType(Singletons.Global g)
-
-
Method Detail
-
getModuleName
public String getModuleName()
-
getSootClass
public SootClass getSootClass()
Get the SootClass object corresponding to this RefType.- Overrides:
getSootClassin classRefType- Returns:
- the corresponding SootClass
-
merge
public Type merge(Type other, Scene cm)
Returns the least common superclass of this type and other.
-
getArrayElementType
public Type getArrayElementType()
Description copied from class:RefLikeTypeIf 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.- Overrides:
getArrayElementTypein classRefType
-
-