Author: limpbizkit
Date: Thu Jul 16 11:07:46 2009
New Revision: 1045

Modified:
    wiki/FrequentlyAskedQuestions.wiki

Log:
Edited wiki page through web user interface.

Modified: wiki/FrequentlyAskedQuestions.wiki
==============================================================================
--- wiki/FrequentlyAskedQuestions.wiki  (original)
+++ wiki/FrequentlyAskedQuestions.wiki  Thu Jul 16 11:07:46 2009
@@ -154,5 +154,17 @@
  }}}
  This also allows for a default value for the optional parameter.

+===How do I inject a method interceptor?===
+In order to inject dependencies in an AOP `MethodInterceptor`, use  
`requestInjection()` alongside the standard `bindInterceptor` call.
+{{{
+public class NotOnWeekendsModule extends AbstractModule {
+  protected void configure() {
+    MethodInterceptor interceptor = new WeekendBlocker();
+    requestInjection(interceptor);
+    bindInterceptor(any(), annotatedWith(NotOnWeekends.class),  
interceptor);
+  }
+}
+}}}
+
  ===How can I get other questions answered?===
  Please post to the [http://groups.google.com/group/google-guice  
google-guice] discussion group.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"google-guice-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-guice-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to