当前位置: 首页>>代码示例>>Java>>正文


Java Instruction23x.getOpcode方法代码示例

本文整理汇总了Java中org.jf.dexlib2.iface.instruction.formats.Instruction23x.getOpcode方法的典型用法代码示例。如果您正苦于以下问题:Java Instruction23x.getOpcode方法的具体用法?Java Instruction23x.getOpcode怎么用?Java Instruction23x.getOpcode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.jf.dexlib2.iface.instruction.formats.Instruction23x的用法示例。


在下文中一共展示了Instruction23x.getOpcode方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: jimplify

import org.jf.dexlib2.iface.instruction.formats.Instruction23x; //导入方法依赖的package包/类
public void jimplify (DexBody body) {
      if(!(instruction instanceof Instruction23x))
          throw new IllegalArgumentException("Expected Instruction23x but got: "+instruction.getClass());

      Instruction23x aPutInstr = (Instruction23x)instruction;
      int source = aPutInstr.getRegisterA();

      Local arrayBase = body.getRegisterLocal(aPutInstr.getRegisterB());
      Local index = body.getRegisterLocal(aPutInstr.getRegisterC());
      ArrayRef arrayRef = Jimple.v().newArrayRef(arrayBase, index);

      Local sourceValue = body.getRegisterLocal(source);
      assign = getAssignStmt(body, sourceValue, arrayRef);
      if (aPutInstr.getOpcode().value == Opcode.APUT_OBJECT.value)
        assign.addTag(new ObjectOpTag());
      
      setUnit(assign);
      addTags(assign);
      body.add(assign);
      
if (IDalvikTyper.ENABLE_DVKTYPER) {
	Debug.printDbg(IDalvikTyper.DEBUG, "constraint: "+ assign);
        DalvikTyper.v().addConstraint(assign.getLeftOpBox(), assign.getRightOpBox());
        DalvikTyper.v().setType(arrayRef.getIndexBox(), IntType.v(), true);
      }
  }
 
开发者ID:flankerhqd,项目名称:JAADAS,代码行数:27,代码来源:AputInstruction.java

示例2: newBuilderInstruction23x

import org.jf.dexlib2.iface.instruction.formats.Instruction23x; //导入方法依赖的package包/类
@Nonnull
private BuilderInstruction23x newBuilderInstruction23x(@Nonnull Instruction23x instruction) {
    return new BuilderInstruction23x(
            instruction.getOpcode(),
            instruction.getRegisterA(),
            instruction.getRegisterB(),
            instruction.getRegisterC());
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:9,代码来源:BuilderMutableMethodImplementation.java

示例3: of

import org.jf.dexlib2.iface.instruction.formats.Instruction23x; //导入方法依赖的package包/类
public static ImmutableInstruction23x of(Instruction23x instruction) {
    if (instruction instanceof ImmutableInstruction23x) {
        return (ImmutableInstruction23x)instruction;
    }
    return new ImmutableInstruction23x(
            instruction.getOpcode(),
            instruction.getRegisterA(),
            instruction.getRegisterB(),
            instruction.getRegisterC());
}
 
开发者ID:CvvT,项目名称:andbg,代码行数:11,代码来源:ImmutableInstruction23x.java

示例4: jimplify

import org.jf.dexlib2.iface.instruction.formats.Instruction23x; //导入方法依赖的package包/类
public void jimplify (DexBody body) throws InvalidDalvikBytecodeException {
      if(!(instruction instanceof Instruction23x))
          throw new IllegalArgumentException("Expected Instruction23x but got: "+instruction.getClass());

      Instruction23x aGetInstr = (Instruction23x)instruction;
      int dest = aGetInstr.getRegisterA();
     
      Local arrayBase = body.getRegisterLocal(aGetInstr.getRegisterB());
      Local index = body.getRegisterLocal(aGetInstr.getRegisterC());

      ArrayRef arrayRef = Jimple.v().newArrayRef(arrayBase, index);
      Local l = body.getRegisterLocal(dest);
      
      assign = Jimple.v().newAssignStmt(l, arrayRef);
      if (aGetInstr.getOpcode().value == Opcode.AGET_OBJECT.value)
        assign.addTag(new ObjectOpTag());

      setUnit(assign);
      addTags(assign);
      body.add(assign);
      
if (IDalvikTyper.ENABLE_DVKTYPER) {
	Debug.printDbg(IDalvikTyper.DEBUG, "constraint: "+ assign);
        DalvikTyper.v().addConstraint(assign.getLeftOpBox(), assign.getRightOpBox());
        DalvikTyper.v().setType(arrayRef.getIndexBox(), IntType.v(), true);
      }
  }
 
开发者ID:flankerhqd,项目名称:JAADAS,代码行数:28,代码来源:AgetInstruction.java

示例5: of

import org.jf.dexlib2.iface.instruction.formats.Instruction23x; //导入方法依赖的package包/类
public static ImmutableInstruction23x of(Instruction23x instruction) {
    if (instruction instanceof ImmutableInstruction23x) {
        return (ImmutableInstruction23x) instruction;
    }
    return new ImmutableInstruction23x(
            instruction.getOpcode(),
            instruction.getRegisterA(),
            instruction.getRegisterB(),
            instruction.getRegisterC());
}
 
开发者ID:niranjan94,项目名称:show-java,代码行数:11,代码来源:ImmutableInstruction23x.java


注:本文中的org.jf.dexlib2.iface.instruction.formats.Instruction23x.getOpcode方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。