• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to convert a jar/war file of .class files to a folder containing .java files

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI ,
I want to know how to convert a .jad file to .java file,
i have large number of .jad files[around 4000] to .java files,
is there any tool to do this,
please reply me , if you know about it,
thanks in advance
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can't you just rename the files (*.jad -> *.java)?
 
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As per my understanding, you mean to ask how to convert class files to java files. If this is the query then the answer is that you unzip/untar the war/jar files to a folder and then use a decompiler to decompile the classes to java files. DJ Decompiler is one that I can suggest. However, there can be many available on the net.
 
karthik sreeram
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for replying,
what i want exactly is to rename a bulk amount of .jad files to .java files,
is there any tool to rename a directory of files from .jad to .java.
 
Chetan Raju
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
ren *.jad *.java should work if im not wrong
 
Ranch Hand
Posts: 1847
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Chetan Raju:
ren *.jad *.java should work if im not wrong



if you're on a Windows machine and they're all in the same directory

But the principle is sound, other operating systems have similar commands, some of them may even have an option to recursively process deeper directories.
 
Ranch Hand
Posts: 239
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Write a Java program to rename the files.
 
karthik sreeram
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks the renaming utility is working , but it is renaming the files in the current directory only,
but i want to rename the entire directory tree containing .jad files to .java files, how can i?
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you aware that Jad has an option that allows you to set the extension being used for decompiled files? That way there would be no need to rename the files.
 
karthik sreeram
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks , jad is working ,thanks everyone , i got my solution.
reply
    Bookmark Topic Watch Topic
  • New Topic