Author: struberg
Date: Fri Jan  4 23:50:31 2013
New Revision: 1429170

URL: http://svn.apache.org/viewvc?rev=1429170&view=rev
Log:
OWB-344 add more JavaDoc

Modified:
    
openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept/WebBeansInterceptorConfig.java

Modified: 
openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept/WebBeansInterceptorConfig.java
URL: 
http://svn.apache.org/viewvc/openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept/WebBeansInterceptorConfig.java?rev=1429170&r1=1429169&r2=1429170&view=diff
==============================================================================
--- 
openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept/WebBeansInterceptorConfig.java
 (original)
+++ 
openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept/WebBeansInterceptorConfig.java
 Fri Jan  4 23:50:31 2013
@@ -384,18 +384,19 @@ public final class WebBeansInterceptorCo
     }
 
     /*
-     * Find the deployed interceptors with given interceptor binding types.
+     * Find the deployed interceptors with all the given interceptor binding 
types.
+     * The reason why we can face multiple InterceptorBindings is because of 
the transitive
+     * behaviour of @InterceptorBinding. See section 9.1.1 of the CDI 
spec.
      */
-    public Set<Interceptor<?>> findDeployedWebBeansInterceptor(Annotation[] 
anns)
+    public Set<Interceptor<?>> findDeployedWebBeansInterceptor(Annotation[] 
interceptorBindingTypes)
     {
         Set<Interceptor<?>> set = new HashSet<Interceptor<?>>();
 
         Iterator<Interceptor<?>> it = 
webBeansContext.getInterceptorsManager().getInterceptors().iterator();
-        WebBeansInterceptorBean<?> interceptor;
 
         List<Class<? extends Annotation>> bindingTypes = new ArrayList<Class<? 
extends Annotation>>();
         List<Annotation> listAnnot = new ArrayList<Annotation>();
-        for (Annotation ann : anns)
+        for (Annotation ann : interceptorBindingTypes)
         {
             bindingTypes.add(ann.annotationType());
             listAnnot.add(ann);
@@ -403,7 +404,7 @@ public final class WebBeansInterceptorCo
 
         while (it.hasNext())
         {
-            interceptor = (WebBeansInterceptorBean<?>) it.next();
+            WebBeansInterceptorBean<?> interceptor = 
(WebBeansInterceptorBean<?>) it.next();
 
             if (interceptor.hasBinding(bindingTypes, listAnnot))
             {


Reply via email to