Why not build-time only? For the tooling, the scr tooling we have in the Felix project is extensible and works with Maven, Ant and bndtools support is there as well.
I already see people "implementing" AdapterProvider but forgetting the annotation on a method or vice versa. And they don't notice their problem until late at runtime and only at the point where the adapter is needed. If we can move all the checking to build time, this is much safer. As the code resides in a bundle and the bundle needs to be build anyway, I don't see a use case for runtime annotation processing. Regards Carsten 2013/7/4 Bertrand Delacretaz <[email protected]> > On Thu, Jul 4, 2013 at 10:28 AM, Bertrand Delacretaz > <[email protected]> wrote: > > On Thu, Jul 4, 2013 at 8:56 AM, Carsten Ziegeler <[email protected]> > wrote: > >> One solution for a build time annotation would be to define a server > >> registration property for a AdapterProvider containing the method > names... > > > > That's much more complicated to write than just an @Adapter annotation > > on a method... > > Ah sorry, reread your message and I overlooked the "at build time the > value of this property would be generated by using the annotation" > part - still, I don't want this to be build-time only. > > -Bertrand > -- Carsten Ziegeler [email protected]
