Package soot.jimple
Class Constant
- java.lang.Object
-
- soot.jimple.Constant
-
- All Implemented Interfaces:
Serializable,EquivTo,Immediate,ConvertToBaf,Switchable,Value
- Direct Known Subclasses:
ClassConstant,FunctionPointerConstant,MethodHandle,MethodType,NullConstant,NumericConstant,SEvaluator.MetaConstant,StringConstant,UntypedConstant
public abstract class Constant extends Object implements Value, ConvertToBaf, Immediate
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Constant()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectclone()Clones the current constant.voidconvertToBaf(JimpleToBafContext context, List<Unit> out)Adds a Baf instruction pushing this constant to the stack ontoout.intequivHashCode()Returns a hash code consistent with structural equality for this object.booleanequivTo(Object c)Returns true if this object is structurally equivalent to c.List<ValueBox>getUseBoxes()Returns a List of boxes corresponding to Values which are used by (ie contained within) this Value.voidtoString(UnitPrinter up)-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface soot.util.Switchable
apply
-
-
-
-
Method Detail
-
getUseBoxes
public final List<ValueBox> getUseBoxes()
Description copied from interface:ValueReturns a List of boxes corresponding to Values which are used by (ie contained within) this Value.- Specified by:
getUseBoxesin interfaceValue
-
convertToBaf
public void convertToBaf(JimpleToBafContext context, List<Unit> out)
Adds a Baf instruction pushing this constant to the stack ontoout.- Specified by:
convertToBafin interfaceConvertToBaf
-
clone
public Object clone()
Clones the current constant. Not implemented here.
-
equivTo
public boolean equivTo(Object c)
Returns true if this object is structurally equivalent to c. For Constants, equality is structural equality, so we just call equals().
-
equivHashCode
public int equivHashCode()
Returns a hash code consistent with structural equality for this object. For Constants, equality is structural equality; we hope that each subclass defines hashCode() correctly.- Specified by:
equivHashCodein interfaceEquivTo
-
toString
public void toString(UnitPrinter up)
-
-