com.caucho.ejb.session
Class AbstractSessionManager<X>

java.lang.Object
  extended by com.caucho.ejb.server.AbstractEjbBeanManager<X>
      extended by com.caucho.ejb.session.AbstractSessionManager<X>
All Implemented Interfaces:
EnvironmentBean
Direct Known Subclasses:
SingletonManager, StatefulManager, StatelessManager

public abstract class AbstractSessionManager<X>
extends AbstractEjbBeanManager<X>

Server container for a session bean.


Field Summary
 
Fields inherited from class com.caucho.ejb.server.AbstractEjbBeanManager
_ejbClass, _ejbManager, _filename, _line, _location, _mappedName, _ut
 
Constructor Summary
AbstractSessionManager(EjbManager manager, java.lang.String ejbName, java.lang.String moduleName, AnnotatedType<X> rawAnnType, AnnotatedType<X> annotatedType, EjbLazyGenerator<X> lazyGenerator)
           
 
Method Summary
 void bind()
           
protected abstract
<T> Bean<T>
createBean(ManagedBeanImpl<X> mBean, java.lang.Class<T> api, java.util.Set<java.lang.reflect.Type> apiList, AnnotatedType<X> extAnnType)
           
protected  BeanGenerator<X> createBeanGenerator()
          Creates the bean generator for the session bean.
protected
<T> SessionProxyFactory<T>
createProxyFactory(AbstractSessionContext<X,T> context)
           
protected
<T> AbstractSessionContext<X,T>
createSessionContext(java.lang.Class<T> api)
           
 void destroy()
          Cleans up the server on shutdown
protected  Bean<X> getBean()
           
protected  java.lang.Class<?> getContextClass()
           
 Bean<X> getDeployBean()
           
 InjectManager getInjectManager()
           
protected  EjbLazyGenerator<X> getLazyGenerator()
           
 java.util.ArrayList<AnnotatedType<? super X>> getLocalApi()
           
 AnnotatedType<X> getLocalBean()
           
<T> T
getLocalProxy(java.lang.Class<T> api)
          Returns the a new local stub for the given API
 java.lang.Class<?> getProxyImplClass()
           
 java.util.ArrayList<AnnotatedType<? super X>> getRemoteApi()
           
protected  SessionBeanType getSessionBeanType()
           
protected
<T> AbstractSessionContext<X,T>
getSessionContext(java.lang.Class<T> api)
           
protected  java.lang.String getType()
           
 void init()
          Initialize the server during the config phase.
 
Methods inherited from class com.caucho.ejb.server.AbstractEjbBeanManager
bindContext, bindInjection, createInjectionTarget, destroy, destroyInstance, encodeId, error, getAnnotatedType, getClassLoader, getContext, getContext, getContext, getEjbClass, getEjbContainer, getEJBName, getId, getLocalJndiProxy, getMappedName, getModuleInjectManager, getModuleName, getProtocolId, getProtocolId, getRawAnnotatedType, getRemoteApiList, getRemoteObject, getServerProgram, getTimerService, getTransactionTimeout, getUserTransaction, hasRemoteObject, invalidateCache, isContainerTransaction, isDead, isDependValid, lookup, newInstance, postStart, registerInjection, setAroundInvoke, setBusinessLocal, setConfigLocation, setContainerTransaction, setEjbClass, setId, setLocation, setMappedName, setRemoteApiList, setResourceList, setServerProgram, setTransactionTimeout, start, timeout, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractSessionManager

public AbstractSessionManager(EjbManager manager,
                              java.lang.String ejbName,
                              java.lang.String moduleName,
                              AnnotatedType<X> rawAnnType,
                              AnnotatedType<X> annotatedType,
                              EjbLazyGenerator<X> lazyGenerator)
Method Detail

getType

protected java.lang.String getType()
Overrides:
getType in class AbstractEjbBeanManager<X>

getDeployBean

public Bean<X> getDeployBean()
Overrides:
getDeployBean in class AbstractEjbBeanManager<X>

getProxyImplClass

public java.lang.Class<?> getProxyImplClass()

getInjectManager

public InjectManager getInjectManager()
Overrides:
getInjectManager in class AbstractEjbBeanManager<X>

getLazyGenerator

protected EjbLazyGenerator<X> getLazyGenerator()

getLocalApi

public java.util.ArrayList<AnnotatedType<? super X>> getLocalApi()
Overrides:
getLocalApi in class AbstractEjbBeanManager<X>

getRemoteApi

public java.util.ArrayList<AnnotatedType<? super X>> getRemoteApi()
Overrides:
getRemoteApi in class AbstractEjbBeanManager<X>

getLocalBean

public AnnotatedType<X> getLocalBean()
Overrides:
getLocalBean in class AbstractEjbBeanManager<X>

getSessionContext

protected <T> AbstractSessionContext<X,T> getSessionContext(java.lang.Class<T> api)

init

public void init()
          throws java.lang.Exception
Initialize the server during the config phase.

Overrides:
init in class AbstractEjbBeanManager<X>
Throws:
java.lang.Exception

bind

public void bind()
Overrides:
bind in class AbstractEjbBeanManager<X>

createBeanGenerator

protected BeanGenerator<X> createBeanGenerator()
Creates the bean generator for the session bean.


getLocalProxy

public <T> T getLocalProxy(java.lang.Class<T> api)
Description copied from class: AbstractEjbBeanManager
Returns the a new local stub for the given API

Specified by:
getLocalProxy in class AbstractEjbBeanManager<X>
Parameters:
api - the bean's api to return a value for

createSessionContext

protected <T> AbstractSessionContext<X,T> createSessionContext(java.lang.Class<T> api)

createProxyFactory

protected <T> SessionProxyFactory<T> createProxyFactory(AbstractSessionContext<X,T> context)

getContextClass

protected java.lang.Class<?> getContextClass()

getBean

protected Bean<X> getBean()

createBean

protected abstract <T> Bean<T> createBean(ManagedBeanImpl<X> mBean,
                                          java.lang.Class<T> api,
                                          java.util.Set<java.lang.reflect.Type> apiList,
                                          AnnotatedType<X> extAnnType)

getSessionBeanType

protected SessionBeanType getSessionBeanType()

destroy

public void destroy()
Description copied from class: AbstractEjbBeanManager
Cleans up the server on shutdown

Overrides:
destroy in class AbstractEjbBeanManager<X>