Package sootup.core.jimple.common
Class Local
java.lang.Object
sootup.core.jimple.common.Local
- Direct Known Subclasses:
JavaLocal
Local variable in
Body. Use LocalGenerator to generate locals.
Prefer to use the factory methods in Jimple.
- Author:
- Linghui Luo
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<V extends ImmediateVisitor>
Vaccept(@NonNull V v) Called when this object is visited.final booleanintReturns a (not necessarily fixed) hash code for this object.booleanequivTo(@NonNull Object o, @NonNull JimpleComparator comparator) Returns true if this object is equivalent to o according to the given comparator.getDefs(Collection<Stmt> defs) returns a List that can contain: Locals, JFieldRefs, JArrayRefsgetDefsForLocalUse(StmtGraph<?> graph, Stmt stmt) Get all definition-stmts which define the given local used by the given stmt.@NonNull StringgetName()Returns the name of this object.getStmtsUsingOrDefiningthisLocal(Collection<Stmt> stmts, Stmt removedStmt) @NonNull TypegetType()Returns the type of this local.getUses()Returns a List of Locals,FieldRefs,ArrayRefs which are used by (ie contained within) this Expression or Reference.final inthashCode()toString()voidtoString(@NonNull StmtPrinter up) @NonNull Local@NonNull Local
-
Constructor Details
-
Local
Constructs a JimpleLocal of the given name and type.
-
-
Method Details
-
equals
-
hashCode
public final int hashCode() -
equivTo
Description copied from interface:EquivToReturns true if this object is equivalent to o according to the given comparator. -
equivHashCode
public int equivHashCode()Description copied from interface:EquivToReturns a (not necessarily fixed) hash code for this object. This hash code coincides with equivTo; it is undefined in the presence of mutable objects. The contract is defined inJimpleComparator.- Specified by:
equivHashCodein interfaceEquivTo
-
getName
Returns the name of this object. -
getType
Returns the type of this local. -
toString
-
toString
-
getUses
Description copied from interface:ValueReturns a List of Locals,FieldRefs,ArrayRefs which are used by (ie contained within) this Expression or Reference. -
getDefs
returns a List that can contain: Locals, JFieldRefs, JArrayRefs -
getDefsForLocalUse
Get all definition-stmts which define the given local used by the given stmt.- Parameters:
graph- a stmt graph which contains the given stmts.stmt- a stmt which uses the given local.
-
getStmtsUsingOrDefiningthisLocal
-
accept
Description copied from interface:AcceptorCalled when this object is visited.- Specified by:
acceptin interfaceAcceptor<ImmediateVisitor>
-
withName
-
withType
-