Home  >  Article  >  Java  >  How to decompile bytecode files in Java?

How to decompile bytecode files in Java?

王林
王林forward
2023-04-22 14:40:081912browse

1. Description

(1) javap, the built-in decompilation tool javap, can decompile bytecode files. javap-help can understand the basic usage of javap.

(2) Enter the command javap-verbose-pMain.class to view the output content.

2. Usage examples

用法: javap <options> <classes>
其中, 可能的选项包括:
  -help  --help  -?        输出此用法消息
  -version                 版本信息
  -v  -verbose             输出附加信息
  -l                       输出行号和本地变量表
  -public                  仅显示公共类和成员
  -protected               显示受保护的/公共类和成员
  -package                 显示程序包/受保护的/公共类
                           和成员 (默认)
  -p  -private             显示所有类和成员
  -c                       对代码进行反汇编
  -s                       输出内部类型签名
  -sysinfo                 显示正在处理的类的
                           系统信息 (路径, 大小, 日期, MD5 散列)
  -constants               显示最终常量
  -classpath <path>        指定查找用户类文件的位置
  -cp <path>               指定查找用户类文件的位置
  -bootclasspath <path>    覆盖引导类文件的位置

What can Java be used for?

Java is mainly used in: 1. web development; 2. Android development; 3 . Client development; 4. Web development; 5. Enterprise-level application development; 6. Java big data development; 7. Game development, etc.

The above is the detailed content of How to decompile bytecode files in Java?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:yisu.com. If there is any infringement, please contact admin@php.cn delete