We had a developer leave our company and now I am having to pickup the pieces. Looks like I am missing some JSP files, however I do have the _JSP.Java files in my classes folder for those JSP files. does anyone know of a tool that would take the pre-compiled _JSP.Java files and create JSP files?
ANy help is much appreciated... Also i would like to know in general , How to create Java File from .class file ?
Meri Zindagi Hain Tab Tak.. Jab Tak Tera Sahara.... Har Taraf Tu Hi Tu Hain SAI Tera Hi Hain Nazara.....
Eeeek! I feel for you! There is no tool that I know of that would decompile a JSP Java class back to its JSP source, and, I imagine if there were, it wouldn't be able to do a very good job of it since so much info will have not been preserved. Java decompilers are another matter and you will find info on them in the general Java forums.
Were it me, I'd look at the page in action, use the generated java code as a guideline, and reverse engineer the page by hand. [ April 06, 2006: Message edited by: Bear Bibeault ]
How complicated were the original JSPs? If there was a lot of stuff in them, including custom tags, the code is likely to be a mess. If they were small or fairly straight-forward pages, it might not be so bad.
Feel free to drop in with more questions if you run into trouble. We might be able to help you decipher some of problem areas (though no promises, of course).
Is there no way to track down the ex-developer and torture him until he coughs up the original JSPs? [ April 06, 2006: Message edited by: Bear Bibeault ]
Also stating the completely obvious, take a look at the html source generated by the jsp/servlet. That could potentially also help with reverse engineering the page. It depends what proportion of the page was dynamic, how much it included java scriptlet code etc etc...
Just out of interest, what server are you guys using? One of the issues with "untranslating" JSPs is that every server generates the java code differently, using their own support classes. It would be impossible to write a generic one. [ April 06, 2006: Message edited by: Stefan Evans ]
Joined: Apr 04, 2006
Hey Guys , Thx for your replies.. I have managed to make those .java files to its equivalent jsp's by referring each line of it.. That was the killing day !!! I wonder how easy JSP is after that day ! However , Now i have a small question. We use Tomcat 5.0.16 as our server and i would like to know is there any way we can use Snchroniuzation Token in Jsp's .. I have heard that it is being used in Struts. But i want to know can the same be used in JSP and if it can be , i would appreciate if someone can post a snippet for it so that i can atleast get an idea of it..