I am a trainer and my project is to upgrade a transcompiler from Java 1.3 to 1.5, I am a beginner in Java and I want to khnow if there is a tool that will help me, I took the first step by reading the new features of 1.4 and 1.5 then we decided that I have to add this features : Generics - Metadata - Autoboxing - Enumerations - Var args - Enhanced for each loop. So if you can tell me what is the next step and if there is a tool that upgrade the code to a recent version ? thank you
-
Please read How to Ask. There's no tool that will upgrade code that I know of.Jonathan Drapeau– Jonathan Drapeau2014-01-10 13:30:28 +00:00Commented Jan 10, 2014 at 13:30
-
Java is usually pretty good at being backwards compatible. It will probably "just work"Richard Tingle– Richard Tingle2014-01-10 13:31:20 +00:00Commented Jan 10, 2014 at 13:31
Add a comment
|
1 Answer
Just try to compile and then test the code, fix anything that doesn't work.
You don't have to use the new features just because they are there.
Why upgrade to 5 though? You should go to 7 really if going through the pain of doing an upgrade as the extra pain will be very small and you will be up to date for longer.
2 Comments
Tanboula
I did ask why not to upgrade to 1.7 and they said they will see if there is a feature that will need in 1.6 or 1.7, you suggest to compile the code but that's not what I need because the transcompiler work well but they want to change the source code ( I don't know why) to a recent version
Tim B
1.7 is more recent, is properly maintained, has security fixes, better performance, etc. It's not a matter of needing a specific feature.