• Embed Doc
  • Readcast
  • Collections
  • CommentGo Back
Download
 
RetroJ User's Guide
Version 1.0
Copyright © 2009 by Numiton
 
RetroJ 1.0 User's Guide
Table of Contents
1. Overview................................................................................................................................................32. Language feature transformations..........................................................................................................42.1 Java 1.4 features..............................................................................................................................42.1.1 Assertions................................................................................................................................42.2 Java 1.5 features..............................................................................................................................52.2.1 Generics...................................................................................................................................52.2.2 Enhanced FOR loop.................................................................................................................62.2.3 Autoboxing/unboxing..............................................................................................................62.2.4 Typesafe enums.......................................................................................................................82.2.5 Varargs.....................................................................................................................................92.2.6 Static import..........................................................................................................................102.2.7 Annotations............................................................................................................................102.3 Java 1.6 features............................................................................................................................113. Installation and usage...........................................................................................................................113.1 Command-line...............................................................................................................................113.2 Ant task..........................................................................................................................................123.3 Eclipse plug-in...............................................................................................................................133.3.1 Installation.............................................................................................................................133.3.2 Configuration.........................................................................................................................133.3.3 Usage.....................................................................................................................................144. Licensing..............................................................................................................................................145. Support.................................................................................................................................................14Page 2 of 17
 
RetroJ 1.0 User's Guide
1. Overview
RetroJ is a commercial tool that enables developers to work with newer versions of Java, even if thedeployment platform uses an older version. Well-known examples are the
 Java ME 
and
 Blu-Ray
 platforms (based on the JDK 1.3 language features). In general many companies choose to be cautiouswith adopting new Java versions, preferring stability over a richer feature set.Since more recent language features (especially in JDK 1.5) enable the writing of clearer, moreexpressive code, developers get to benefit from them. At the same time, platform limitations arerespected by running RetroJ as part of the packaging/deployment process (and maintaining theconverted version as a read-only version, to avoid confusion).Since generated source code is visible to the developers, not obfuscated and maintaining formatting andcomments, they get to ensure that nothing “fishy” happened during downgrading.There are other tools that offer this type of downgrading (e.g
 RetroWeaver 
fromhttp://retroweaver.sourceforge.net/, open-source). But they do it at bytecode level and this black-boxnature can be an unsatisfactory aspect to some developers/companies. Numiton views RetroJ as asource-level alternative to byte-code level tools, when such an alternative is preferable to users.The RetroJ team is committed to providing professional support to its clients, as specified in the licenseagreement.RetroJ currently supports downgrades between JDK1.6 and JDK1.3 (or any combination in-between).As new Java versions are launched by Sun, future RetroJ releases will cover the freshly-introducedlanguage features.Please note that using API specific to a newer JDK is not supported by RetroJ. Such scenarios will bedetected prior to deployment, since the compilation of the downgraded code produces linkage errors.Section2of this guide explains the transformations performed by RetroJ. These are related to:
assertions
annotations
autoboxing/unboxing
enhanced FOR loops
generics
static imports
typesafe enums
varargsSection3details the RetroJ installation and usage:
via command-linePage 3 of 17
of 00

Leave a Comment

You must be to leave a comment.
Submit
Characters: ...
You must be to leave a comment.
Submit
Characters: ...