Hi Laurent,

Please look into the cocoon.xconf for the configuration of eclipse compiler and set the value to "1.5" instead of "auto". Here is the code:

<!--+
55 : | Specifies the java code source version used to compile the XSP code.
56 :                    |
57 :                    | Posible values:
58 :                    | 1.3 = Java version 1.3
59 :                    | 1.4 = Java version 1.4
60 :                    | 1.5 = Java version 1.5
61 : | auto = The version of the JVM where cocoon is running. (Default value).
62 :                    |
63 :                    | NOTE: The parameter is optional to keep backward 
compatibility.
64 : anathaniel 555089 <http://svn.apache.org/viewvc/cocoon/branches/BRANCH_2_1_X/src/blocks/xsp/conf/xsp-program-language.xconf?view=diff&pathrev=555089&r1=555088&r2=555089> | The parameter works with Sun Javac compiler and the Eclipse compiler. 65 : antonio 124779 <http://svn.apache.org/viewvc/cocoon/branches/BRANCH_2_1_X/src/blocks/xsp/conf/xsp-program-language.xconf?view=diff&pathrev=555089&r1=124778&r2=124779> | The pizza compiler does not support java 1.5.
66 :                    +-->
67 :                    <!-- <parameter name="compiler-compliance-level" 
value="auto"/> -->


Best Regards,

Antonio Gallardo

El 21/08/09 09:27, Laurent Medioni escribió:
Hello,
Still with our Cocoon 2.1.11 on a 1.6 JVM series...
Just noticed that 
org.apache.cocoon.components.language.programming.java.EclipseJavaCompiler does 
not know anything about 1.6 (nothing wrong with this as it uses JDT 3.1) but in 
this case defaults to... 1.3, which is quite a big step back from 1.4 ;).
It is possible to force the compliance level to 1.5 through the xconf parameter 
compiler-compliance-level but no configuration is possible for the generated 
class file compatibility, which does not obey to the same parameter...

I tried to replace JDT 3.1 by the latest 3.5 and locally patched 
EclipseJavaCompiler to manage a 1.6 value... For the moment it works well...

Cheers,
Laurent

____________________________________________________________

� This email and any files transmitted with it are CONFIDENTIAL and intended
   solely for the use of the individual or entity to which they are addressed.
� Any unauthorized copying, disclosure, or distribution of the material within
   this email is strictly forbidden.
� Any views or opinions presented within this e-mail are solely those of the
   author and do not necessarily represent those of Odyssey Financial
Technologies SA unless otherwise specifically stated.
� An electronic message is not binding on its sender. Any message referring to
   a binding engagement must be confirmed in writing and duly signed.
� If you have received this email in error, please notify the sender immediately
   and delete the original.

Reply via email to