4.4. Working with J2SE

With J2SE v1.4, javadoc introduced the -source flag for processing APIs that used J2SE v1.4 specific features, such as the assert keyword. So, if you're going to populate such an API, or J2SE itself, you must specify ashkelon's corresponding flag: --source, like this:

   $ ashkelon add --source 1.4 j2sdk14.xml
         

Another concern is that although it's very convenient to have ashkelon fetch the source code on our behalf directly from version control, this is not always possible or practical. For example, you'll more likely manually download J2SE source code for processing. ashkelon has a provision for this. You can define a SOURCEPATH environment variable containing however many paths you need where source code resides that you want to process through ashkelon.

So, assume you download J2SE to ~/devel/j2se/sources. Simply add that path to your SOURCEPATH environment variable (in a completely analogous fashion to the way we work with CLASSPATH). Then, simply omit the <repository> section from the api descriptor file (it's optional). ashkelon will simply fall back to looking for the j2se source code in your source path.