[weld-dev] TCK Interceptors Classes

Gurkan Erdogdu gurkanerdogdu at yahoo.com
Mon Nov 30 14:17:22 EST 2009


There are two differents scenario for lifecycle callbacks in interceptors specification

1* Used in interceptor class with InvocationContext parameter
     @PreDestroy
     public void blabla(InvocationContext){}
2* Used in bean class without any parameter
     @PreDestroy
     public void blabla(){}


In TCK, @PreDestroy is used in interceptor class. So it may take InvocationContext.

--Gurkan



________________________________
From: Gavin King <gavin.king at gmail.com>
To: Gurkan Erdogdu <gurkanerdogdu at yahoo.com>
Cc: weld-dev at lists.jboss.org
Sent: Mon, November 30, 2009 9:10:17 PM
Subject: Re: [weld-dev] TCK Interceptors Classes

Hrm, I think there are two kinds of @PreDestroy methods for an interceptor:

@PreDestroy void foo(InvocationContext) { .. }  -> the intercepted
bean is being destroyed
@PreDestroy void foo() { .. }  -> the interceptor itself is being destroyed

Right?

On Mon, Nov 30, 2009 at 1:34 PM, Gurkan Erdogdu <gurkanerdogdu at yahoo.com> wrote:
> Hi;
>
> Some interceptors classes in the TCK test suites implement @PreDestroy
> methods. AFAIK, interceptors specification says that methods with
> @PreDestroy in interceptor class must take InvocationContext parameter. But
> in TCK, those methods do not take InvocationContext parameter
>
> For example:
>
> org.jboss.jsr299.tck.tests.context.dependent.TransactionalInterceptor
>
> @PreDestroy public void destroy()
>    {
>       destroyed = true;
>    }
>
> Is it correct?
>
> --Gurkan
>
>
>
>
> _______________________________________________
> weld-dev mailing list
> weld-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/weld-dev
>



-- 
Gavin King
gavin.king at gmail.com
http://in.relation.to/Bloggers/Gavin
http://hibernate.org
http://seamframework.org



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/weld-dev/attachments/20091130/1c982107/attachment.html 


More information about the weld-dev mailing list