The javap is a utility program that provides us with information on Java .class files. It is a Java class file disassembler that dissembles Java bytecode. We can use the utility to disassemble one or more .class files.
Java source code is compiled into machine-independent bytecode .class files. The javac Java compiler compiles *.java source code to *.class bytecode files. Java Bytecode is interpreted by machine-specific JVMs.
The javap tool is used to verify the profile of the class or interface. By default, the internal details of the class or interface will be displayed on the console window. The tool is usually found under the bin directory of the JDK home directory.
To know all the supported flags:
\> javap –help
The -c command-line switch will disassemble the Java Bytecode.
The general syntax of the tool is shown below:
\> javap <fully_qualified_name_of_the_class/interface>
\> javap Hello.class
If no command line switches are used, javap prints out the variables and methods of the class file.
To disassemble the bytecode, use the -c command line switch:
\>javap -c Hello.class
For example, to know the internal details of the System class, we can use the following command:
\> javap java.lang.System
Java Tutorial on this website:
For more information on Java, visit the official website :