Class Opcodes

java.lang.Object
org.jf.dexlib2.Opcodes

public class Opcodes extends Object
  • Field Details

    • api

      public final int api
      Either the api level for dalvik opcodes, or the art version for art opcodes
    • artVersion

      public final int artVersion
    • opcodesByValue

      @Nonnull private final Opcode[] opcodesByValue
    • opcodeValues

      @Nonnull private final EnumMap<Opcode,Short> opcodeValues
    • opcodesByName

      @Nonnull private final HashMap<String,Opcode> opcodesByName
  • Constructor Details

    • Opcodes

      private Opcodes(int api, int artVersion)
  • Method Details

    • forApi

      @Nonnull public static Opcodes forApi(int api)
    • forArtVersion

      @Nonnull public static Opcodes forArtVersion(int artVersion)
    • forDexVersion

      @Nonnull public static Opcodes forDexVersion(int dexVersion)
    • getDefault

      @Nonnull public static Opcodes getDefault()
      Returns:
      a default Opcodes instance for when the exact Opcodes to use doesn't matter or isn't known
    • getOpcodeByName

      @Nullable public Opcode getOpcodeByName(@Nonnull String opcodeName)
    • getOpcodeByValue

      @Nullable public Opcode getOpcodeByValue(int opcodeValue)
    • getOpcodeValue

      @Nullable public Short getOpcodeValue(@Nonnull Opcode opcode)
    • isArt

      public boolean isArt()