Exemplo n.º 1
0
 public void caseClassConstant(ClassConstant c) {
   // "array class" types are unmodified
   boolean classIsArray = c.value.startsWith("[");
   String className = classIsArray ? c.value : SootToDexUtils.getDexClassName(c.value);
   TypeIdItem referencedClass = TypeIdItem.internTypeIdItem(stmtV.getBelongingFile(), className);
   stmtV.addInsn(new Insn21c(Opcode.CONST_CLASS, destinationReg, referencedClass));
 }
Exemplo n.º 2
0
 public void caseFloatConstant(FloatConstant f) {
   int intBits = Float.floatToIntBits(f.value);
   stmtV.addInsn(buildConstInsn(intBits));
 }
Exemplo n.º 3
0
 public void caseDoubleConstant(DoubleConstant d) {
   long longBits = Double.doubleToLongBits(d.value);
   stmtV.addInsn(buildConstWideInsn(longBits));
 }
Exemplo n.º 4
0
 public void caseLongConstant(LongConstant l) {
   long constant = l.value;
   stmtV.addInsn(buildConstWideInsn(constant));
 }
Exemplo n.º 5
0
 public void caseStringConstant(StringConstant s) {
   StringIdItem referencedString =
       StringIdItem.internStringIdItem(stmtV.getBelongingFile(), s.value);
   stmtV.addInsn(new Insn21c(Opcode.CONST_STRING, destinationReg, referencedString));
 }
Exemplo n.º 6
0
 public void caseNullConstant(NullConstant v) {
   // dex bytecode spec says: "In terms of bitwise representation, (Object) null == (int) 0."
   stmtV.addInsn(buildConstInsn(0));
 }
Exemplo n.º 7
0
 public void caseIntConstant(IntConstant i) {
   stmtV.addInsn(buildConstInsn(i.value));
 }