@Nonnull @Override public Opcodes getOpcodes() { return dexFile.getOpcodes(); } }
@Nonnull @Override public Opcodes getOpcodes() { return dexFile.getOpcodes(); } }
public static ImmutableDexFile of(DexFile dexFile) { if (dexFile instanceof ImmutableDexFile) { return (ImmutableDexFile)dexFile; } return new ImmutableDexFile(dexFile.getOpcodes(), dexFile.getClasses()); }
public static ImmutableDexFile of(DexFile dexFile) { if (dexFile instanceof ImmutableDexFile) { return (ImmutableDexFile)dexFile; } return new ImmutableDexFile(dexFile.getOpcodes(), dexFile.getClasses()); }
public static void writeTo(@Nonnull String path, @Nonnull org.jf.dexlib2.iface.DexFile input) throws IOException { DexPool dexPool = new DexPool(input.getOpcodes()); for (ClassDef classDef: input.getClasses()) { dexPool.internClass(classDef); } dexPool.writeTo(new FileDataStore(new File(path))); }
public static void writeTo(@Nonnull String path, @Nonnull org.jf.dexlib2.iface.DexFile input) throws IOException { DexPool dexPool = new DexPool(input.getOpcodes()); for (ClassDef classDef: input.getClasses()) { dexPool.internClass(classDef); } dexPool.writeTo(new FileDataStore(new File(path))); }
public static void writeTo(@Nonnull DexDataStore dataStore, @Nonnull org.jf.dexlib2.iface.DexFile input) throws IOException { DexPool dexPool = new DexPool(input.getOpcodes()); for (ClassDef classDef: input.getClasses()) { dexPool.internClass(classDef); } dexPool.writeTo(dataStore); }
public static void writeTo(@Nonnull DexDataStore dataStore, @Nonnull org.jf.dexlib2.iface.DexFile input) throws IOException { DexPool dexPool = new DexPool(input.getOpcodes()); for (ClassDef classDef: input.getClasses()) { dexPool.internClass(classDef); } dexPool.writeTo(dataStore); }
Iterable<? extends org.jf.dexlib2.iface.instruction.Instruction> deodex() { try { DexFileModule m = myClass.getContainer(); ClassPathResolver path = new ClassPathResolver(Collections.singletonList(m.getFile().getParent() + '/'), Collections.<String>emptyList(), m.getDexFile()); ClassPath cp = new ClassPath(path.getResolvedClassProviders(), false, m.getDexFile().getOpcodes().artVersion); MethodAnalyzer analyzer = new MethodAnalyzer(cp, eMethod, null, false); return analyzer.getInstructions(); } catch (Exception e) { assert false : e; return eMethod.getImplementation().getInstructions(); } }
Iterable<? extends org.jf.dexlib2.iface.instruction.Instruction> deodex() { try { DexFileModule m = myClass.getContainer(); ClassPathResolver path = new ClassPathResolver(Collections.singletonList(m.getFile().getParent() + '/'), Collections.<String>emptyList(), m.getDexFile()); ClassPath cp = new ClassPath(path.getResolvedClassProviders(), false, m.getDexFile().getOpcodes().artVersion); MethodAnalyzer analyzer = new MethodAnalyzer(cp, eMethod, null, false); return analyzer.getInstructions(); } catch (Exception e) { assert false : e; return eMethod.getImplementation().getInstructions(); } }
throws IOException { this.classPathDirs = bootClassPathDirs; this.pathEntryLoader = new PathEntryLoader(dexFile.getOpcodes()); bootClassPathEntries = getDefaultBootClassPath(dexFile, dexFile.getOpcodes().api);
throws IOException { this.classPathDirs = bootClassPathDirs; this.pathEntryLoader = new PathEntryLoader(dexFile.getOpcodes()); bootClassPathEntries = getDefaultBootClassPath(dexFile, dexFile.getOpcodes().api);
DexFile f = DexFileFactory.loadDexFile(url.getFile(), Opcodes.getDefault()); SyntheticAccessorResolver sar = new SyntheticAccessorResolver(f.getOpcodes(), f.getClasses());