[cdi-dev] [JBoss JIRA] (CDI-468) Extend javax.interceptor.InvocationContext

Martin Kouba (JIRA) issues at jboss.org
Tue Sep 16 08:57:05 EDT 2014


    [ https://issues.jboss.org/browse/CDI-468?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13002840#comment-13002840 ] 

Martin Kouba commented on CDI-468:
----------------------------------

[~arnelim] Well, it does care, since v1.2 (Java EE 7), see also Chapter 3,  "Associating Interceptors using Interceptor Bindings".
{quote}
Anyway it would be way better, if such method would be located directly in the InvocationContext (and not in a sub-interface)
{quote}
Agreed.

> Extend javax.interceptor.InvocationContext
> ------------------------------------------
>
>                 Key: CDI-468
>                 URL: https://issues.jboss.org/browse/CDI-468
>             Project: CDI Specification Issues
>          Issue Type: Feature Request
>            Reporter: Arne Limburg
>
> Currently there is no easy way to obtain the interceptor binding annotation for an interceptor call. The interceptor binding annotation is needed to access @Nonbinding attributes and behave accordingly.
> I propose to extend the javax.interceptor.InvocationContext interface with a method
> public Annotation getInterceptorBinding() or
> public <A extends Annotation> A getInterceptorBinding(Class<A> type)
> The @AroundInvoke method of CDI Interceptors may use this extended interface as parameter instead of the original one to obtain the interceptor binding annotation.



--
This message was sent by Atlassian JIRA
(v6.3.1#6329)


More information about the cdi-dev mailing list