>>>>> On Tue, 13 Oct 2015 09:32:53 +0100, Richard Evans <richard.d.evans_at_oracle.com> said:
RE> I'm experimenting with a ServletContainerInitializer. I'd like to find
RE> all annotation classes with are themselves annotated with a specific
RE> annotation - for example @A.
RE> So I have A.class in the @HandlesTypes annotaton of the
RE> ServletContainerInitializer. But I am getting different results
RE> depending on application server.
Yes, I've observed cross app-server differences in this behavior as
well.
RE> In WebLogic 12 onStartup /is/ passed annotation classes which are
RE> annotated with @A. In Tomcat 8 I do not get these classes.
RE> The servlet 3.1 spec says:
RE> "The HandlesTypes annotation on the implementation of the
RE> ServletContainerInitializer is used to express interest in classes that
RE> may have annotations (type, method or field level annotations) specified
RE> in the value of the HandlesTypes or if it extends/implements one those
RE> classes anywhere in the class' super types."
RE> Does class here imply a concrete class? Or can be be anything -
RE> interface, annotation - which has a corresponding Java class?
I'll defer to Shing-wai for a more authoritative answer, but in my
experience it is safest to interpret it as "concrete class".
Thanks,
Ed
--
| edward.burns_at_oracle.com | office: +1 407 458 0017
| 8 Business days til JavaOne 2015
| 24 Business days til DOAG 2015