public class


extends DecompilerExporter
   ↳ com.pnfsoftware.jeb.core.units.code.DecompilerExporter

Class Overview

Helper class used to decompile and export to *.java files all or a subset of classes or methods of a DEX unit.

Example: export all top-level classes to an output folder:

 IDexDecompilerUnit dexdec = ...; // retrieve from the current IRuntimeProject
 File outdir = ...;
 DexDecompilerExporter exp = dexdec.getExporter();
 exp.setOutputFolder(outdir, false);
 exp.setMethodTimeout(60_000L);  // safety
 exp.setTotalTimeout(15 * 60_000L);  // safety
 exp.setCallback(new ProgressCallbackAdapter() {
     public void message(String msg) {
 boolean success = exp.processTopLevelClasses();
 System.out.println("Errors: " + exp.getErrors());


Inherited Fields
From class com.pnfsoftware.jeb.core.units.code.DecompilerExporter
Public Constructors
DexDecompilerExporter(IDexDecompilerUnit decompiler)
Public Methods
boolean process()
Decompile and export all meaningful elements.
void setSignaturePattern(Pattern pattern)
The strings that will be provided to the matcher are jvm (canonical) class or method signatures, e.g.
Protected Methods
String generateClassFileName(String csig)
String generateMethodFileName(String msig)
Inherited Methods
From class com.pnfsoftware.jeb.core.units.code.DecompilerExporter
From class java.lang.Object

Public Constructors

public DexDecompilerExporter (IDexDecompilerUnit decompiler)

Public Methods

public boolean process ()

Decompile and export all meaningful elements. This is the recommended method to call. Top-level classes and their constituents will be exported; orphaned methods and other items will be exported as well.

If an output folder was specified, the resulting source files will be stored in a folder hierarchy that matches their namespace or package name.

  • true if no error occurred; false if some errors occurred

public void setSignaturePattern (Pattern pattern)

The strings that will be provided to the matcher are jvm (canonical) class or method signatures, e.g. Lcom/abc/Foo; or Lcom/foo/Bar;->m1([I)Ljava/lang/String;.

pattern a regex pattern

Protected Methods

protected String generateClassFileName (String csig)

protected String generateMethodFileName (String msig)