Questions tagged [.class-file]

Class files are the format used by the Java Virtual Machine.

Class files are the format used by the Java Virtual Machine. Java programs are typically compiled into class files, which may be bundled into a jar archive.

283 questions
0
votes
2 answers

Get java compiler version of a class file using xxd

I need to get the version of java that was used to compile a class file from a linux machine that doesn't have java. I have learned from a comment on this post that this is possible using xxd. Alternatively, if you open the class file in a hex…
Jack J
  • 1,514
  • 3
  • 20
  • 28
0
votes
0 answers

.class file too large

I have a kotlin file with a function that returns a list of strings with 10,000 elements, but when compiling it generates an error, saying that the .class file is too large. What I can do? return listOf( "string 1", "string 2", ... "string 10,000"…
chrrissoft
  • 149
  • 1
  • 10
0
votes
0 answers

How to decompile java class files?

I am working on a static analysis tool for java applications. In one of the tasks I need to present the security analysis of a method and the corresponding method from the source code. In the case of a java project where the source files are…
0
votes
1 answer

Java runs in eclipse and will compile, but wont execute on cmd, but still runs in eclipse. How can I get it to execute in cmd?

So I have a basic hello world set up in eclipse and I can compile it using cmd easily (I have set all the necessary paths), however when I then try to use the java command to execute the hello world, it always returns the same error: Error: Could…
PythonSux
  • 27
  • 3
0
votes
0 answers

I Can't Change the Read-Only Status of .class Files in intellij

Image I downloaded a .class file and opened it in Intellij, I pressed the lock button in bottom right corner and File>Make File Writable but I still can't edit the .class file. I own the file and have full permission.
Tepedibi
  • 1
  • 1
0
votes
0 answers

Authors in two columns for IEEEcsmag.cls

In IEEEcsmag.cls template for an IEEE magazine, authors can be added as follows (default). \documentclass{IEEEcsmag} \usepackage{hyperref} \usepackage{upmath} \begin{document} \title{Title:...} \author{F. A. Author} \affil{First…
Mt.Guchi
  • 11
  • 1
0
votes
1 answer

Can I assume the capacity of a Java data structure is proportional to the memory taken by then data structure instance when the program is executed?

My intention is to analyze the bytecode of a Java program and collect the data about the data structures that have been used. That data includes the initial capacity and how the particular data structure has grown throughout the runtime(growing…
0
votes
2 answers

What format of file does linker produce after linking .class files produced by compiler in JAVA

While working with JAVA when compiler compiles are .java classes. It produces .class files and after compilation, the linker links all .class files to create one single file. My question is that what use to be the extension of that single file…
Umair
  • 585
  • 3
  • 9
  • 21
0
votes
2 answers

How javap works for java library files?

JRE contains the .class files for library classes. When these .class files in JRE folder will be used? Does JRE contains the .class files for all library classes. Let us take an example.. when we are importing the library files, we are using the…
Muthu Ganapathy Nathan
  • 3,199
  • 16
  • 47
  • 77
0
votes
1 answer

.class file not being created in Sublime Text: Java

I am starting to learn Java and decided to use sublime text. I prepared a build system that would allow me to both compile and run the program. When I created my first file, it gave an error: Error: Could not find or load main class…
Sam_Pam
  • 27
  • 1
  • 4
0
votes
0 answers

Javac doesn't recompile referenced classes after changes in referenced java source file

My main.java file calls Tree.java which inturn calls TreeNode.java file. Whenever I compile for first time using main.java. everything runs perfect.but then if I made any changes in Treenode.java,it doesn't recompile it's class file and I get same…
0
votes
0 answers

Why are my bin directories not getting filled with .class files?

Im practicing java, and I noticed that in my older projects, my bin directories have "mirror images" of "something.java" files. But now they just dont seem to appear, no matter what I do. Is it a problem? If it is, how should I solve this? My app is…
user12389421
0
votes
2 answers

Is there a meaningful difference between running .class or .java?

I'm starting Java, and was reading the "Hello World!" for Microsoft Windows guide from Oracle. In the guide, it tells you to use javac to compile into a .class, then run with java -cp . HelloWorldApp When I tried running it, I didn't run the proper…
TheUltimateGuide
  • 333
  • 3
  • 13
0
votes
3 answers

Does a .jar file need all of the classes installed on a machine to run?

Does a .jar file need all of the classes installed on a machine to run? For example: if I ever distribute a program as a .jar file, will I also need to install all my .class files on the user's machine? If so, is there a way to distribute a java…
Serket
  • 3,785
  • 3
  • 14
  • 45
0
votes
1 answer

Why dont I have run icon next to class in intellij?

I can run java classes on intellij only by right clicking. I dont have run icon on left side of the class and @Test. My java class files are also not .class but .java files all the time, even when I run them. Moreover, I dont get any warning, error…
chicka
  • 61
  • 1
  • 5