You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Taras Puchko <fo...@opensymphony.com> on 2006/04/25 20:57:51 UTC

Re: Java 1.4 support libraries (was [VOTE] Target Java 5, support 1.4

Retrotranslator replaces "extends java.lang.Annotation" with "extends net.sf.retrotranslator.runtime.java.lang.Annotation_", "java.lang.Class.getAnnotation" with "net.sf.retrotranslator.runtime.java.lang._Class.getAnnotation", and so on.
So application developers do not have to be aware of Retrotranslator:
http://cvs.sourceforge.net/viewcvs.py/retrotranslator/Retrotranslator/test/net/sf/retrotranslator/runtime/java/lang/_ClassTestCase.java?view=markup

The only drawback here is that translated code may be incompatible with libraries using Java 5 API directly (mainly because annotations do not extend java.lang.Annotation after translation). So you would have to distribute separate jars for 1.4 and 5.0 platform.

Taras
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=27314&messageID=53964#53964


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Java 1.4 support libraries (was [VOTE] Target Java 5, support

Posted by Taras Puchko <fo...@opensymphony.com>.
Annotations can be read at runtime only if accessing code and annotations are both translated with Retrotranslator.

Taras

> Interesting, separate jars were always in the plan,
> so that isn't a problem.  So you are saying the code
> can still 
> access the annotations at runtime?
> 
> Don
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=27314&messageID=54462#54462


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Java 1.4 support libraries (was [VOTE] Target Java 5, support 1.4

Posted by Don Brown <mr...@twdata.org>.
Interesting, separate jars were always in the plan, so that isn't a problem.  So you are saying the code can still 
access the annotations at runtime?

Don

Taras Puchko wrote:
> Retrotranslator replaces "extends java.lang.Annotation" with "extends net.sf.retrotranslator.runtime.java.lang.Annotation_", "java.lang.Class.getAnnotation" with "net.sf.retrotranslator.runtime.java.lang._Class.getAnnotation", and so on.
> So application developers do not have to be aware of Retrotranslator:
> http://cvs.sourceforge.net/viewcvs.py/retrotranslator/Retrotranslator/test/net/sf/retrotranslator/runtime/java/lang/_ClassTestCase.java?view=markup
> 
> The only drawback here is that translated code may be incompatible with libraries using Java 5 API directly (mainly because annotations do not extend java.lang.Annotation after translation). So you would have to distribute separate jars for 1.4 and 5.0 platform.
> 
> Taras
> ---------------------------------------------------------------------
> Posted via Jive Forums
> http://forums.opensymphony.com/thread.jspa?threadID=27314&messageID=53964#53964
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org