[seam-commits] Seam SVN: r9382 - branches/community/Seam_2_0/src/main/org/jboss/seam.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Wed Oct 22 15:01:16 EDT 2008


Author: danielc.roth
Date: 2008-10-22 15:01:16 -0400 (Wed, 22 Oct 2008)
New Revision: 9382

Modified:
   branches/community/Seam_2_0/src/main/org/jboss/seam/Component.java
Log:
JBSEAM-2402 backport

Modified: branches/community/Seam_2_0/src/main/org/jboss/seam/Component.java
===================================================================
--- branches/community/Seam_2_0/src/main/org/jboss/seam/Component.java	2008-10-22 18:15:29 UTC (rev 9381)
+++ branches/community/Seam_2_0/src/main/org/jboss/seam/Component.java	2008-10-22 19:01:16 UTC (rev 9382)
@@ -80,6 +80,7 @@
 import org.jboss.seam.annotations.datamodel.DataModel;
 import org.jboss.seam.annotations.faces.Converter;
 import org.jboss.seam.annotations.faces.Validator;
+import org.jboss.seam.annotations.intercept.BypassInterceptors;
 import org.jboss.seam.annotations.intercept.InterceptorType;
 import org.jboss.seam.annotations.intercept.Interceptors;
 import org.jboss.seam.annotations.security.Restrict;
@@ -324,6 +325,10 @@
          {
             if ( getBeanClass().isAnnotationPresent(Converter.class) )
             {
+               if(!getBeanClass().isAnnotationPresent(BypassInterceptors.class))
+                    throw new IllegalStateException("Converter " + getBeanClass().getName() 
+                    + " must be annotated with @BypassInterceptors");
+			
                Converter converter = getBeanClass().getAnnotation(Converter.class);
                if ( converter.forClass()!=void.class )
                {
@@ -334,6 +339,10 @@
             }
             if ( getBeanClass().isAnnotationPresent(Validator.class) )
             {
+                if(!getBeanClass().isAnnotationPresent(BypassInterceptors.class))
+                    throw new IllegalStateException("Validator " + getBeanClass().getName() 
+                        + " must be annotated with @BypassInterceptors");
+			
                Validator validator = getBeanClass().getAnnotation(Validator.class);
                String id = validator.id().equals("") ? getName() : validator.id();
                init.getValidators().put( id, getName() );




More information about the seam-commits mailing list