[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-3823) Interceptor implementation limits Interceptors annotation to one class

Lars Huber (JIRA) jira-events at lists.jboss.org
Tue Dec 9 03:03:36 EST 2008


Interceptor implementation limits Interceptors  annotation to one class
-----------------------------------------------------------------------

                 Key: JBSEAM-3823
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-3823
             Project: Seam
          Issue Type: Bug
          Components: Core
    Affects Versions: 2.1.1.GA
         Environment: Seam nightly build
            Reporter: Lars Huber


The implementation of the Seam Interceptor restricts the custom Interceptors to one class. In the Seam code is written to remove this silly restriction (see code below).

@Interceptors({FirstInterceptor.class, SecondInterceptor.class})  // does not work due to impl restriction


 public Interceptor(Class[] classes, Annotation annotation, Component component) 
   {
      if (classes.length!=1)
      {
         //TODO: remove this silly restriction!
         throw new IllegalArgumentException("Must be exactly one interceptor when used as a meta-annotation");
      }
      userInterceptorClass = classes[0];
      ...

Also the @Interceptors is only possible in Annotation declaration and not on classes. This forces you to create for each Interceptor an appropriate annotation (see workaround)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list