/*
* JBoss, the OpenSource J2EE webOS
*
* Distributable under LGPL license.
* See terms of license at gnu.org.
*/
package org.jboss.test.util.ejb;

import javax.ejb.*;

import org.apache.log4j.Category;

/**
 * 
 * @author Rickard Oberg
 * @version $Revision: 1.3.26.1 $
 */
public abstract class SessionSupport
   extends EnterpriseSupport
   implements SessionBean
{
   protected transient Category log = Category.getInstance(getClass());

   protected SessionContext sessionCtx;
   
   public void ejbCreate()
      throws CreateException
   {
   }
   
   public void setSessionContext(SessionContext ctx) 
   {
      sessionCtx = ctx;
   }
    
   public void ejbActivate() 
   {
   }
    
   public void ejbPassivate() 
   {
   }
    
   public void ejbRemove() 
   {
   }

   private void writeObject(java.io.ObjectOutputStream stream)
      throws java.io.IOException
   {
      // nothing
   }
   
   private void readObject(java.io.ObjectInputStream stream)
      throws java.io.IOException, ClassNotFoundException
   {
      // reset logging
      log = Category.getInstance(getClass());
   }
}