3种查看java字节码的方式

1、使用 javap 命令查看字节码

命令格式如下:

javap -c xxx.class

2、Intellij IDEA 中查看字节码

View -> Show bytecode

3、Eclipse 中查看字节码

在 Eclipse 中查看字节码稍显麻烦,需要安装插件,并打开插件窗口,安装和使用方式如下:

Name: bytecode

Location: http://andrei.gmxhome.de/eclipse

安装完后需要重启 Eclipse 才能生效。

Eclipse 打开 ByteCode 插件窗口:

Window-> Show View -> Other -> Java -> Bytecode

猜你喜欢

转载自www.cnblogs.com/aikutao/p/12145664.html