简体   繁体   English

将.class文件转换回文本

[英]Converting .class file back to text

Alright, I was playing around, making a TicTacToe game in Java and when I finished, compiled, made sure everything worked I tried to copy the files to another directory using the cp command. 好吧,我正在玩,在Java中制作TicTacToe游戏,当我完成编译时,确保一切正常我尝试使用cp命令将文件复制到另一个目录。 It took me a few tries to get the arguments right but I succeeded in the end. 我花了几次尝试才得到正确的论点,但最终我成功了。 In the process, however, I did something and now my .java file is binary? 然而,在这个过程中,我做了一些事情,现在我的.java文件是二进制的? Well, it starts with: 好吧,它开始于:

cafe babe 0000 0033 006a 0a00 1e00 3207 cafe babe 0000 0033 006a 0a00 1e00 3207

and then proceeds with similar things 140 lines downwards. 然后向下进行类似的事情140行。 Is there a way to revert it back to text? 有没有办法将其还原为文本?

The .java file is the source file. .java文件是源文件。 The .class is the java compiled file. .class是java编译的文件。

So there is nothing wrong with it. 所以它没有任何问题。

You would still have the .java file. 你仍然会有.java文件。 if you want to decompile your .class file, download the decompiler from the following link and open your .class file in the decompiler 如果要反编译.class文件,请从以下链接下载反编译器并在反编译器中打开.class文件

http://jd.benow.ca/ http://jd.benow.ca/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM