Hi there,
I am currently using an injection mechanism within a custom
web-framework. The injection
is done inside of a component / page by the AbstractComponent /AbstractPage
class
one component / page might extend. The annotation looks like this:
@RequestParameter("name")
String [] parameter;
@Model("favourites") //Fetched by name + type
Favourites favourites;
@ComponentProperty("text") @Required //Fails if required is not present
String componentProperty;
@Property("parent.messages.currentMessage")
String message;
@Message("label.enter_username")
String userNameLabelText;
And so on.
The idea is just that there are some kind of injection types that needs to
be processed.
I found the custom injections section that I think is quite what I need.
The example is about field injection but I need method parameter injection
too. I want
to invoke methods based on actions like form submits or links clicked
pointing to
custom actions or Ajax XHR rewrites etc.
So I need some more information about the difference between field
injection and
parameter injection within constructors and methods.
Also what I want is where and how to register errors. In case of @Required
annotation
that can be mixed with anything else, if the requested object is not
retrievable or
constructable (in terms of model) a error need to be produced. How does one
do it
within a custom injector?
Thanks for your help,
Martin (Kersten),
Germany
--
You received this message because you are subscribed to the Google Groups
"google-guice" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/groups/opt_out.