org.sape.ejbutils.adapters
Class SessionBeanAdapter

java.lang.Object
  extended byorg.sape.ejbutils.adapters.SessionBeanAdapter
All Implemented Interfaces:
javax.ejb.EnterpriseBean, Serializable, javax.ejb.SessionBean

public class SessionBeanAdapter
extends Object
implements javax.ejb.SessionBean

Provides default implementations of the EJB callback methods for a Session Bean.

See Also:
Serialized Form

Field Summary
protected  javax.ejb.SessionContext ctx
          The SessionContext for this instance of the SessionBean
private static org.apache.commons.logging.Log log
           
 
Constructor Summary
SessionBeanAdapter()
           
 
Method Summary
 void ejbActivate()
          Default implementation of ejbActivate().
 void ejbCreate()
          Default implementation of ejbCreate().
 void ejbPassivate()
          Default implementation of ejbPassivate().
 void ejbRemove()
          Default implementation of ejbRemove().
 void setSessionContext(javax.ejb.SessionContext ctx)
          The container calls this method after creating the SessionBean to set its SessionContext.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static final org.apache.commons.logging.Log log

ctx

protected javax.ejb.SessionContext ctx
The SessionContext for this instance of the SessionBean

Constructor Detail

SessionBeanAdapter

public SessionBeanAdapter()
Method Detail

ejbCreate

public void ejbCreate()
               throws javax.ejb.CreateException
Default implementation of ejbCreate(). Simply logs a debug message. Note that ejbCreate() is not a method specified by the SessionBean interface.

Throws:
javax.ejb.CreateException

ejbActivate

public void ejbActivate()
                 throws javax.ejb.EJBException,
                        RemoteException
Default implementation of ejbActivate(). Simply logs a debug message.

Specified by:
ejbActivate in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException
RemoteException

ejbPassivate

public void ejbPassivate()
                  throws javax.ejb.EJBException,
                         RemoteException
Default implementation of ejbPassivate(). Simply logs a debug message.

Specified by:
ejbPassivate in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException
RemoteException

ejbRemove

public void ejbRemove()
               throws javax.ejb.EJBException,
                      RemoteException
Default implementation of ejbRemove(). Simply logs a debug message.

Specified by:
ejbRemove in interface javax.ejb.SessionBean
Throws:
javax.ejb.EJBException
RemoteException

setSessionContext

public void setSessionContext(javax.ejb.SessionContext ctx)
                       throws javax.ejb.EJBException,
                              RemoteException
The container calls this method after creating the SessionBean to set its SessionContext. This method stores the SessionContext in a member variable.

Specified by:
setSessionContext in interface javax.ejb.SessionBean
Parameters:
ctx - The SessionContext for this instance of the SessionBean.
Throws:
javax.ejb.EJBException
RemoteException


Copyright 2003 Sapient Corporation. All Rights Reserved.