public class org.jf.baksmali.HelpCommand extends org.jf.util.jcommander.Command
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.jf.baksmali.HelpCommand
super_class: org.jf.util.jcommander.Command
{
private java.util.List<java.lang.String> commands;
descriptor: Ljava/util/List;
flags: (0x0002) ACC_PRIVATE
Signature: Ljava/util/List<Ljava/lang/String;>;
RuntimeVisibleAnnotations:
com.beust.jcommander.Parameter(description = "If specified, show the detailed usage information for the given commands")
org.jf.util.jcommander.ExtendedParameter(argumentNames = {"commands"})
public void <init>(java.util.List<com.beust.jcommander.JCommander>);
descriptor: (Ljava/util/List;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
invokespecial org.jf.util.jcommander.Command.<init>:(Ljava/util/List;)V
1: aload 0
invokestatic com.google.common.collect.Lists.newArrayList:()Ljava/util/ArrayList;
putfield org.jf.baksmali.HelpCommand.commands:Ljava/util/List;
2: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jf/baksmali/HelpCommand;
0 3 1 commandAncestors Ljava/util/List<Lcom/beust/jcommander/JCommander;>;
Signature: (Ljava/util/List<Lcom/beust/jcommander/JCommander;>;)V
RuntimeVisibleTypeAnnotations:
METHOD_FORMAL_PARAMETER
javax.annotation.Nonnull()
RuntimeVisibleParameterAnnotations:
0:
javax.annotation.Nonnull()
MethodParameters:
Name Flags
commandAncestors
public void run();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=9, args_size=1
start local 0 0: aload 0
getfield org.jf.baksmali.HelpCommand.commandAncestors:Ljava/util/List;
aload 0
getfield org.jf.baksmali.HelpCommand.commandAncestors:Ljava/util/List;
invokeinterface java.util.List.size:()I
iconst_1
isub
invokeinterface java.util.List.get:(I)Ljava/lang/Object;
checkcast com.beust.jcommander.JCommander
astore 1
start local 1 1: aload 0
getfield org.jf.baksmali.HelpCommand.commands:Ljava/util/List;
ifnull 2
aload 0
getfield org.jf.baksmali.HelpCommand.commands:Ljava/util/List;
invokeinterface java.util.List.isEmpty:()Z
ifeq 7
2: StackMap locals: com.beust.jcommander.JCommander
StackMap stack:
getstatic java.lang.System.out:Ljava/io/PrintStream;
new org.jf.util.jcommander.HelpFormatter
dup
invokespecial org.jf.util.jcommander.HelpFormatter.<init>:()V
3: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
invokevirtual org.jf.util.jcommander.HelpFormatter.width:(I)Lorg/jf/util/jcommander/HelpFormatter;
4: aload 0
getfield org.jf.baksmali.HelpCommand.commandAncestors:Ljava/util/List;
invokevirtual org.jf.util.jcommander.HelpFormatter.format:(Ljava/util/List;)Ljava/lang/String;
5: invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
6: goto 58
7: StackMap locals:
StackMap stack:
iconst_0
istore 2
start local 2 8: aload 0
getfield org.jf.baksmali.HelpCommand.commands:Ljava/util/List;
invokeinterface java.util.List.iterator:()Ljava/util/Iterator;
astore 4
goto 52
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int top java.util.Iterator
StackMap stack:
9: aload 4
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast java.lang.String
astore 3
start local 3 10: aload 3
ldc "register-info"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifeq 21
11: iconst_1
istore 2
12: ldc "The --register-info parameter will cause baksmali to generate comments before and after every instruction containing register type information about some subset of registers. This parameter accepts a comma-separated listof values specifying which registers and how much information to include.\n ALL: all pre- and post-instruction registers\n ALLPRE: all pre-instruction registers\n ALLPOST: all post-instruction registers\n ARGS: any pre-instruction registers used as arguments to the instruction\n DEST: the post-instruction register used as the output of the instruction\n MERGE: any pre-instruction register that has been merged from multiple incoming code paths\n FULLMERGE: an extended version of MERGE that also includes a list of all the register types from incoming code paths that were merged"
astore 5
start local 5 13: aload 5
14: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
15: invokestatic org.jf.util.StringWrapper.wrapStringOnBreaks:(Ljava/lang/String;I)Ljava/lang/Iterable;
astore 6
start local 6 16: aload 6
invokeinterface java.lang.Iterable.iterator:()Ljava/util/Iterator;
astore 8
goto 19
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator java.lang.String java.lang.Iterable top java.util.Iterator
StackMap stack:
17: aload 8
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast java.lang.String
astore 7
start local 7 18: getstatic java.lang.System.out:Ljava/io/PrintStream;
aload 7
invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
end local 7 19: StackMap locals:
StackMap stack:
aload 8
invokeinterface java.util.Iterator.hasNext:()Z
ifne 17
end local 6 end local 5 20: goto 52
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator
StackMap stack:
21: aload 3
ldc "input"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifeq 32
22: iconst_1
istore 2
23: ldc "Apks and oat files can contain multiple dex files. In order to specify a particular dex file, the basic syntax is to treat the apk/oat file as a directory. For example, to load the \"classes2.dex\" entry from \"app.apk\", you can use \"app.apk/classes2.dex\".\n\nFor ease of use, you can also specify a partial path to the dex file to load. For example, to load a entry named \"/system/framework/framework.jar:classes2.dex\" from \"framework.oat\", you can use any of the following:\n\"framework.oat/classes2.dex\"\n\"framework.oat/framework.jar:classes2.dex\"\n\"framework.oat/framework/framework.jar:classes2.dex\"\n\"framework.oat/system/framework/framework.jar:classes2.dex\"\n\nIn some rare cases, an oat file could have entries that can't be differentiated with the above syntax. For example \"/blah/blah.dex\" and \"blah/blah.dex\". In this case, the \"blah.oat/blah/blah.dex\" would match both entries and generate an error. To get around this, you can add double quotes around the entry name to specify an exact entry name. E.g. blah.oat/\"/blah/blah.dex\" or blah.oat/\"blah/blah.dex\" respectively."
astore 5
start local 5 24: aload 5
25: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
26: invokestatic org.jf.util.StringWrapper.wrapStringOnBreaks:(Ljava/lang/String;I)Ljava/lang/Iterable;
astore 6
start local 6 27: aload 6
invokeinterface java.lang.Iterable.iterator:()Ljava/util/Iterator;
astore 8
goto 30
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator java.lang.String java.lang.Iterable top java.util.Iterator
StackMap stack:
28: aload 8
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast java.lang.String
astore 7
start local 7 29: getstatic java.lang.System.out:Ljava/io/PrintStream;
aload 7
invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
end local 7 30: StackMap locals:
StackMap stack:
aload 8
invokeinterface java.util.Iterator.hasNext:()Z
ifne 28
end local 6 end local 5 31: goto 52
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator
StackMap stack:
32: aload 3
ldc "classpath"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifeq 43
33: iconst_1
istore 2
34: ldc "When deodexing odex/oat files or when using the --register-info option, baksmali needs to load all classes from the framework files on the device in order to fully understand the class hierarchy. There are several options that control how baksmali finds and loads the classpath entries.\n\nL+ devices (ART):\nWhen deodexing or disassembling a file from an L+ device using ART, you generally just need to specify the path to the boot.oat file via the --bootclasspath/-b parameter. On pre-N devices, the boot.oat file is self-contained and no other files are needed. In N, boot.oat was split into multiple files. In this case, the other files should be in the same directory as the boot.oat file, but you still only need to specify the boot.oat file in the --bootclasspath/-b option. The other files will be automatically loaded from the same directory.\n\nPre-L devices (dalvik):\nWhen deodexing odex files from a pre-L device using dalvik, you generally just need to specify the path to a directory containing the framework files from the device via the --classpath-dir/-d option. odex files contain a list of framework files they depend on and baksmali will search for these dependencies in the directory that you specify.\n\nDex files don't contain a list of dependencies like odex files, so when disassembling a dex file using the --register-info option, and using the framework files from a pre-L device, baksmali will attempt to use a reasonable default list of classpath files based on the api level set via the -a option. If this default list is incorrect, you can override the classpath using the --bootclasspath/-b option. This option accepts a colon separated list of classpath entries. Each entry can be specified in a few different ways.\n - A simple filename like \"framework.jar\"\n - A device path like \"/system/framework/framework.jar\"\n - A local relative or absolute path like \"/tmp/framework/framework.jar\"\nWhen using the first or second formats, you should also specify the directory containing the framework files via the --classpath-dir/-d option. When using the third format, this option is not needed.\nIt's worth noting that the second format matches the format used by Android for the BOOTCLASSPATH environment variable, so you can simply grab the value of that variable from the device and use it as-is.\n\nExamples:\n For an M device:\n adb pull /system/framework/arm/boot.oat /tmp/boot.oat\n baksmali deodex blah.oat -b /tmp/boot.oat\n For an N+ device:\n adb pull /system/framework/arm /tmp/framework\n baksmali deodex blah.oat -b /tmp/framework/boot.oat\n For a pre-L device:\n adb pull /system/framework /tmp/framework\n baksmali deodex blah.odex -d /tmp/framework\n Using the BOOTCLASSPATH on a pre-L device:\n adb pull /system/framework /tmp/framework\n export BOOTCLASSPATH=`adb shell \"echo \\\\$BOOTCLASPATH\"`\n baksmali disassemble --register-info ARGS,DEST blah.apk -b $BOOTCLASSPATH -d /tmp/framework"
astore 5
start local 5 35: aload 5
36: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
37: invokestatic org.jf.util.StringWrapper.wrapStringOnBreaks:(Ljava/lang/String;I)Ljava/lang/Iterable;
astore 6
start local 6 38: aload 6
invokeinterface java.lang.Iterable.iterator:()Ljava/util/Iterator;
astore 8
goto 41
StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator java.lang.String java.lang.Iterable top java.util.Iterator
StackMap stack:
39: aload 8
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast java.lang.String
astore 7
start local 7 40: getstatic java.lang.System.out:Ljava/io/PrintStream;
aload 7
invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
end local 7 41: StackMap locals:
StackMap stack:
aload 8
invokeinterface java.util.Iterator.hasNext:()Z
ifne 39
end local 6 end local 5 42: goto 52
43: StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int java.lang.String java.util.Iterator
StackMap stack:
aload 1
aload 3
invokestatic org.jf.util.jcommander.ExtendedCommands.getSubcommand:(Lcom/beust/jcommander/JCommander;Ljava/lang/String;)Lcom/beust/jcommander/JCommander;
astore 5
start local 5 44: aload 5
ifnonnull 47
45: getstatic java.lang.System.err:Ljava/io/PrintStream;
new java.lang.StringBuilder
dup
ldc "No such command: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 3
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
46: goto 52
47: StackMap locals: com.beust.jcommander.JCommander
StackMap stack:
iconst_1
istore 2
48: getstatic java.lang.System.out:Ljava/io/PrintStream;
new org.jf.util.jcommander.HelpFormatter
dup
invokespecial org.jf.util.jcommander.HelpFormatter.<init>:()V
49: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
invokevirtual org.jf.util.jcommander.HelpFormatter.width:(I)Lorg/jf/util/jcommander/HelpFormatter;
50: aload 5
invokevirtual com.beust.jcommander.JCommander.getObjects:()Ljava/util/List;
iconst_0
invokeinterface java.util.List.get:(I)Ljava/lang/Object;
checkcast org.jf.util.jcommander.Command
invokevirtual org.jf.util.jcommander.Command.getCommandHierarchy:()Ljava/util/List;
invokevirtual org.jf.util.jcommander.HelpFormatter.format:(Ljava/util/List;)Ljava/lang/String;
51: invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
end local 5 end local 3 52: StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander int top java.util.Iterator
StackMap stack:
aload 4
invokeinterface java.util.Iterator.hasNext:()Z
ifne 9
53: iload 2
ifne 58
54: getstatic java.lang.System.out:Ljava/io/PrintStream;
new org.jf.util.jcommander.HelpFormatter
dup
invokespecial org.jf.util.jcommander.HelpFormatter.<init>:()V
55: invokestatic org.jf.util.ConsoleUtil.getConsoleWidth:()I
invokevirtual org.jf.util.jcommander.HelpFormatter.width:(I)Lorg/jf/util/jcommander/HelpFormatter;
56: aload 0
getfield org.jf.baksmali.HelpCommand.commandAncestors:Ljava/util/List;
invokevirtual org.jf.util.jcommander.HelpFormatter.format:(Ljava/util/List;)Ljava/lang/String;
57: invokevirtual java.io.PrintStream.println:(Ljava/lang/String;)V
end local 2 58: StackMap locals: org.jf.baksmali.HelpCommand com.beust.jcommander.JCommander
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 59 0 this Lorg/jf/baksmali/HelpCommand;
1 59 1 parentJc Lcom/beust/jcommander/JCommander;
8 58 2 printedHelp Z
10 52 3 cmd Ljava/lang/String;
13 20 5 registerInfoHelp Ljava/lang/String;
16 20 6 lines Ljava/lang/Iterable<Ljava/lang/String;>;
18 19 7 line Ljava/lang/String;
24 31 5 registerInfoHelp Ljava/lang/String;
27 31 6 lines Ljava/lang/Iterable<Ljava/lang/String;>;
29 30 7 line Ljava/lang/String;
35 42 5 registerInfoHelp Ljava/lang/String;
38 42 6 lines Ljava/lang/Iterable<Ljava/lang/String;>;
40 41 7 line Ljava/lang/String;
44 52 5 command Lcom/beust/jcommander/JCommander;
}
SourceFile: "HelpCommand.java"
NestMembers:
org.jf.baksmali.HelpCommand$HlepCommand
InnerClasses:
public HlepCommand = org.jf.baksmali.HelpCommand$HlepCommand of org.jf.baksmali.HelpCommand
RuntimeVisibleAnnotations:
com.beust.jcommander.Parameters(commandDescription = "Shows usage information")
org.jf.util.jcommander.ExtendedParameters(commandName = "help", commandAliases = {"h"})