1 16 17 package org.springframework.ejb.support; 18 19 import javax.ejb.CreateException ; 20 import javax.ejb.EJBException ; 21 22 import org.apache.commons.logging.Log; 23 import org.apache.commons.logging.LogFactory; 24 25 49 public abstract class AbstractStatelessSessionBean extends AbstractSessionBean { 50 51 52 protected final Log logger = LogFactory.getLog(getClass()); 53 54 55 65 public void ejbCreate() throws CreateException { 66 loadBeanFactory(); 67 onEjbCreate(); 68 } 69 70 78 protected abstract void onEjbCreate() throws CreateException ; 79 80 81 85 public void ejbActivate() throws EJBException { 86 throw new IllegalStateException ("ejbActivate must not be invoked on a stateless session bean"); 87 } 88 89 93 public void ejbPassivate() throws EJBException { 94 throw new IllegalStateException ("ejbPassivate must not be invoked on a stateless session bean"); 95 } 96 97 } 98 | Popular Tags |