Results 1 to 14 of 14
  1. #1
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default hi do you know how to extract jar

    I tried to extract .jar file, then the extracted folder contains only .class.. Can I edit this or see the code?

    Lots thanks

  2. #2
    pbrockway2 is offline Moderator
    Join Date
    Feb 2009
    Location
    New Zealand
    Posts
    4,565
    Rep Power
    12

    Default Re: hi do you know how to extract jar

    A jar file is a sort of zip archive, so you can use anything that will open these.

    From the sound of your question you have extracted the contents of the jar file. If you want to decompile .class files you will need a decompiler like jad. Note: the resulting source files may not be valid, intelligible or legally able to be used.

  3. #3
    pbrockway2 is offline Moderator
    Join Date
    Feb 2009
    Location
    New Zealand
    Posts
    4,565
    Rep Power
    12

    Default Re: hi do you know how to extract jar

    A jar file is a sort of zip archive, so you can use anything that will open these.

    From the sound of your question you have extracted the contents of the jar file. If you want to decompile .class files you will need a decompiler like jad. Note: the resulting source files may not be valid, intelligible or legally able to be used.

  4. #4
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    yep i used jad as decompiler, i already had the code but I can't edit the code.. Do you know how can I edit code?

  5. #5
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default Re: hi do you know how to extract jar

    Quote Originally Posted by RichersooN View Post
    yep i used jad as decompiler, i already had the code but I can't edit the code.. Do you know how can I edit code?
    With an editor or IDE?

  6. #6
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    Quote Originally Posted by Fubarable View Post
    With an editor or IDE?
    Yep with eclipse editor, I can't edit the code.. it is not .java it's .class

  7. #7
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default Re: hi do you know how to extract jar

    Quote Originally Posted by RichersooN View Post
    Yep with eclipse editor, I can't edit the code.. it is not .java it's .class
    Then you're wrong -- you don't have the code but rather the compiled code. Big difference. pbrockway already told you how to possibly get the code. What confuses you about his post?

  8. #8
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    I want to edit the code, do you know how to edit the code? it is not editable

  9. #9
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default Re: hi do you know how to extract jar

    Quote Originally Posted by RichersooN View Post
    I want to edit the code, do you know how to edit the code? it is not editable
    OK, let's take this step by step.
    • You have the class files extracted from the jar file, correct?
    • You've decompiled the class files into Java files, correct?
    • You now can edit the Java (text) files that you've just obtained from the step above.


    What part of the steps above is not working? If you're still stuck, please provide us with plenty of useful detail so we don't have to slowly extract it.
    Last edited by Fubarable; 09-22-2011 at 05:26 AM.

  10. #10
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    I have the class files extracted from the jar file.

    •You've decompiled the class files into Java files, wrong, I just have .class then I can only view the code of that .class in eclipse.
    •You now can edit the Java (text) files that you've just obtained from the step above, wrong, I can't edit the .class because it is not editable.

  11. #11
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default Re: hi do you know how to extract jar

    Quote Originally Posted by RichersooN View Post
    I have the class files extracted from the jar file.

    •You've decompiled the class files into Java files, wrong, I just have .class then I can only view the code of that .class in eclipse.
    •You now can edit the Java (text) files that you've just obtained from the step above, wrong, I can't edit the .class because it is not editable.

    In post number 4 above, you state:
    Quote Originally Posted by RichersooN View Post
    yep i used jad as decompiler, i already had the code but I can't edit the code.. Do you know how can I edit code?
    Now I'm confused. Have you decompiled the class files with JAD or not?

    To simplify this whole thing, why not ask for the source files from the folks who hold the legal rights to them? Then you don't have to muck with all this decompilation, and you'll know that what you're doing is perfectly legal.
    Last edited by Fubarable; 09-22-2011 at 05:31 AM.

  12. #12
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default Re: hi do you know how to extract jar

    Again, have you decompiled the class files as you noted in post #4 of this thread?

    Edit: By your lack of reply I can only guess that you've lost interest in this subject. Well, goodnight.
    Last edited by Fubarable; 09-22-2011 at 05:57 AM.

  13. #13
    RichersooN is offline Senior Member
    Join Date
    Jan 2011
    Location
    Rizal Province, Philippiines
    Posts
    167
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    Yes the only output when I used jad is .class.. it is not .java extension.. I can't edit the code using eclipse.

    The only thing I have is jar. I don't have the source code.

  14. #14
    anthropamorphic's Avatar
    anthropamorphic is offline Senior Member
    Join Date
    Jun 2011
    Posts
    135
    Rep Power
    0

    Default Re: hi do you know how to extract jar

    just get JD-GUI decoder

Similar Threads

  1. How to extract a jar in java
    By kgkamaraj in forum New To Java
    Replies: 3
    Last Post: 02-12-2010, 09:09 AM
  2. How to Extract?
    By KB1SYV in forum New To Java
    Replies: 2
    Last Post: 11-11-2009, 06:51 AM
  3. Extract information from URL
    By ziameraj16 in forum Java Servlet
    Replies: 0
    Last Post: 09-07-2009, 10:50 AM
  4. Extract A tar.gz file
    By sajdutt in forum Advanced Java
    Replies: 3
    Last Post: 03-03-2009, 09:29 AM
  5. Extract xml to store into db
    By palanikumark in forum Advanced Java
    Replies: 3
    Last Post: 06-06-2008, 03:09 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •