Skip to main content
How are we doing? Please help us improve Stack Overflow. Take our short survey

Questions tagged [javap]

javap - The Java Class File Disassembler

javap
0 votes
2 answers
72 views

Is there a way within a bash script to determine the minimum java version required by a jar file containing class files and jar files?

For a single class - we can work out the version of Java used to compile it: javap -verbose className I have a scenario where I need to scale this up to a jar file containing many classes and jar ...
hawkeye's user avatar
  • 35.3k
0 votes
0 answers
409 views

javap command not working with %JAVA_HOME% being set

Im deep diving into the JVM architecture and I wanted to inspect the constant pool for one of my java classes which belongs to a Spring Boot project. I have my compiled java class and I am trying to ...
rwd762's user avatar
  • 31
0 votes
1 answer
83 views

javac reports "package does not exist" even though classpath is set

I have a file Test.java (stripped down for debugging): import com.github.tkutche1.jgrade.Grade; I try compiling it with this command line and get an error: # javac -cp lib/com/github/tkutche1/jgrade/...
Ellen Spertus's user avatar
0 votes
1 answer
46 views

Why does an anonymous inner class have such type when I disassemble the class file using javac?

When I disassembled the code given below, I noticed that the TestClass's anonymous inner class in constant pool is displayed as 'AnonymousTestApp$1', but shouldn't it be 'TestClass$1'? The code: ...
ChpokHead's user avatar
1 vote
0 answers
148 views

How to syntax highlight a hex dump of JVM classfile?

I'm studying binary file structure of JVM classfile. My current toolbox consists of $ xxd <classfile> and $ javap -v <classfile>. Sample outputs of these two tools are as follows: $ xxd ...
Takashi's user avatar
  • 31
0 votes
1 answer
128 views

How to read a file from nested jar at Linux?

Is there any way to read some files from a jar inside the "outer" jar with javap command? for example, I want to read the a.class A.jar |----/lib/ |---B.jar | ...
hsseol's user avatar
  • 21
1 vote
0 answers
2k views

Downgrading java version in project (IntelliJ)

I am trying to downgrade the target build version of java, but somehow I can´t change it within IntelliJ, don´t understeand why. Under File -> Project Structure -> Projects I changed the ...
WinterMute's user avatar
0 votes
2 answers
108 views

Can java disassembled code run without OS?

I disassembled a java class file to Assembly using javap. Then Can I run the assembly code generated by the javap command without Os? Or is there something like il2cpu.net for java?
scardon's user avatar
  • 714
1 vote
2 answers
290 views

java internal method signature doesn't match constructor parameters (javap)

I have the following class containing local inner class: class Outer { private boolean beep; private int foo; public Outer(boolean beep) { this.beep = beep; } public void ...
joker's user avatar
  • 3,604
0 votes
0 answers
751 views

Javap Command Error in Java On Command Prompt

Why javap command is not running in command prompt and its showing javap is not recognised as internal or external command except javap all other command is running well.
sakshi mishra's user avatar
0 votes
0 answers
55 views

How to write scala jar executable by Java to fetch hostname of the machine?

I want to perform this activity in Scala and execute it with Java: hostname -i The scala code for this is: import java.net._ object HostName { def main(args: Array[String]){ val ...
Aviral Srivastava's user avatar
2 votes
1 answer
128 views

Why, after compiling an interface, "default" method modifier is gone from "javap -v"?

I have observed, that after compiling an interface containing default method definition, like: interface Delta { default void someMethod() { System.out.println("Hi."); } } ...
Giorgi Tsiklauri's user avatar
4 votes
1 answer
212 views

Problem marking the lines in the java compiler

I am a master's student and I am researching static analysis. In one of my tests I came across a problem in marking lines in the java compiler. I have the following java code: 226: String json = &...
Matheus Barbosa's user avatar
1 vote
1 answer
843 views

How to load a class from module(.jmod) file at runtime?

I want to load classes from a module (.jmod) file at runtime into the application memory. I know that we can easily load classes from a (.jar) file using :-) ClassLoader loader = URLClassLoader....
Omega UI's user avatar
0 votes
1 answer
106 views

grep method appears in class file but not in its human dump

I'm grepping for a method getNumBytes in some class file A.class: $ grep -rn "getNumBytes" Binary file A.class matches When I dump its content with javap I can't see my method: $ javap -c -...
OrenIshShalom's user avatar

15 30 50 per page
1
2 3 4 5
9