Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » J2EE Interest »

Re: setSessionContext methods significance !

Tim Wood

2004-07-30


At 04:55 PM 07/30/04, Jagannath Nori wrote:
>Hi,
>
>I want to know what exactly does adding the method in an EJB accomplish ?? I know it is a mandatory method but wanted to know the significance of it.
>
>public void setSessionContext(javax.ejb.SessionContext aContext) {
>     context=aContext;
>   }

Look up the methods in SessionContext. You can't do any of those things in your bean if you don't capture the SC in a variable (preferably instance). setSessionContext() is part of what the J2EE container does to implement the bean lifecycle.
TW

===========================================================================
To unsubscribe, send email to listserv@(protected)
of the message "signoff J2EE-INTEREST". For general help, send email to
listserv@(protected)".
©2008 junlu.com - Jax Systems, LLC, U.S.A.