Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • 1
    Why do you care what's in the .class file? The .class file is compiled, you should only care about the .java file. Commented Apr 26, 2011 at 21:10
  • 1
    Yeah, it was never really necessary for the VM to work, it just was added to be able to distinguish Java class files from other types of files, even if the name of the file is not known. (It is not used by the VM for this purpose, though.) Commented Apr 27, 2011 at 0:17
  • 2
    @Nik - It is a question out of interest - I ran into a term I'm not familiar with and after reading about it I was puzzled about it. It's not like I'm gonna write a .class file parser now ... Commented Apr 27, 2011 at 4:54
  • 2
    @Nik If you are interested in doing any bytecode reading and/or manipulation, then you will be very interested in the .class file. Commented Oct 7, 2011 at 17:02