[jboss-user] [Javassist user questions] - Method Paramater annotation not seen on Scala class - but vi

fanf42 do-not-reply at jboss.com
Tue Mar 10 13:27:59 EDT 2009


Hello,

I'm trying to use Tapestry 5.0.18 with Scala (2?7?3 and 2.8.0 nightly). It uses method parameter annotations that seem to not be found by Javassist (tested with 3.8, 3.9 and 3.10 GA).

The annotation is a java annotation declared as this :
8<------------------------------------
@Target({PARAMETER, FIELD})
@Retention(RUNTIME)
@Documented
public @interface InjectService
{
    String value();
}
8<------------------------------------

And is used like :
8<------------------------------------
public static void contributeFooService(
                OrderedConfiguration conf,
        @InjectService("foo1") FooService foo1,
        @InjectService("foo2") FooService foo2
    ) { .... }
8<------------------------------------

As the problem appear with Scala file, I'm not sur that it's only a javassist problem, but the symptom are :

- in Java, I saw annotation both woth Javassist CtBehavior#getAvailableParameterAnnotations() and with Java reflexion API java.lang.reflect.Method#getAvailableAnnotations

- in Scala, I saw the annotation only with the java reflexion API

I don't know exactly what I can provides to help here.
Any help would be appreciated,
Francois Armand

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4216675#4216675

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4216675



More information about the jboss-user mailing list