[jdom-interest] JDOM with generics

Victor Toni victor.toni at ebuconnect.de
Sat May 6 00:35:35 PDT 2006


Jason Hunter wrote:
>>>> Can code using the Collections API (java.util.List, java.util.Map, 
>>>> ...) and compiled using JDK 1.2 be run under JDK 1.5, where the 
>>>> Collections API is implemented with generics...?
>>>
>>> Yes.  But new tech is always better at supporting old tech than vice 
>>> versa.
>>
>> Is there any vice versa in this case? You would only use the generics 
>> enabled JDOM JAR if you in fact are running JDK 1.5 or newer. 
>
> Ever graph the JAR dependency graph of a big project?  It's crazy.  :)
>
> The issue is what happens when your Java 5 program depends on JDOM 5 
> but also on a package that depends on JDOM 1.0?  Serious question.  
> You can't assume you can recompile the package because it's not yours. 
> Assuming it was compiled against JDK 1.2, can it understand the JDOM 5 
> JAR adequately?

I would second the idea of having a JDOM 1.5 which is identical to 1.0 
(or maybe better 1.0.1 ; -) ) expect that it uses Generics. It should be 
as compatible for older projects as is the 1.5 runtime.

Victor


More information about the jdom-interest mailing list