com.caucho.ejb.gen
Class SessionGenerator<X>

java.lang.Object
  extended by com.caucho.java.gen.ClassComponent
      extended by com.caucho.java.gen.BaseClass
          extended by com.caucho.java.gen.GenClass
              extended by com.caucho.config.gen.BeanGenerator<X>
                  extended by com.caucho.ejb.gen.SessionGenerator<X>
Direct Known Subclasses:
SingletonGenerator, StatefulGenerator, StatelessGenerator

@Module
public abstract class SessionGenerator<X>
extends BeanGenerator<X>

Generates the skeleton for a session bean.


Field Summary
protected  java.lang.String _contextClassName
           
 
Constructor Summary
SessionGenerator(java.lang.String ejbName, AnnotatedType<X> beanType, java.util.ArrayList<AnnotatedType<? super X>> localApi, AnnotatedType<X> localBean, java.util.ArrayList<AnnotatedType<? super X>> remoteApi, java.lang.String beanTypeName)
           
 
Method Summary
protected  void addBusinessMethod(AnnotatedMethod<? super X> method)
           
protected  void addNonBusinessMethod(AnnotatedMethod<? super X> method)
           
protected  void addPostConstructMethod(AnnotatedMethod<? super X> method)
           
protected  void addPreDestroyMethod(AnnotatedMethod<? super X> method)
           
protected  void addScheduledMethod(AnnotatedMethod<? super X> method)
           
protected  void generateContentImpl(JavaWriter out, java.util.HashMap<java.lang.String,java.lang.Object> map)
           
protected  void generatePostConstruct(JavaWriter out, java.util.HashMap<java.lang.String,java.lang.Object> map)
           
protected  java.util.ArrayList<AnnotatedMethod<? super X>> getAnnotatedMethods()
          Returns the merged annotated methods
protected abstract  AspectBeanFactory<X> getAspectBeanFactory()
           
protected  AspectBeanFactory<X> getLifecycleAspectFactory()
           
 java.util.ArrayList<AnnotatedType<? super X>> getLocalApi()
          Returns the local API list.
 AnnotatedType<X> getLocalBean()
           
 java.util.ArrayList<AspectGenerator<X>> getMethods()
          Returns the introspected methods
 java.util.ArrayList<AnnotatedType<? super X>> getRemoteApi()
          Returns the remote API list.
protected  AspectBeanFactory<X> getScheduledAspectBeanFactory()
           
 boolean hasNoInterfaceView()
           
 void introspect()
          Introspects the bean.
protected  AnnotatedType<? super X> introspectLocalDefault()
           
static boolean isBusinessMethod(java.lang.reflect.Method method)
           
 boolean isStateless()
           
protected abstract  boolean isTimerSupported()
           
static java.lang.String toFullClassName(java.lang.String ejbName, java.lang.String className, java.lang.String beanType)
           
 
Methods inherited from class com.caucho.config.gen.BeanGenerator
addDependency, addDependency, generateBeanConstructor, generateBeanConstructor, generateBeanPrologue, generateBusinessMethods, generateClassStaticFields, generateContextObjectConstructor, generateDelegate, generateDependency, generateDestroy, generateDestroyImpl, generateDestroyViews, generateEpilogue, generateFreeInstance, generateInject, generateInjectContent, generateLifecycleMethod, generateLifecycleMethodReflection, generateLifecycleMethods, generatePostConstructImpl, generateProxyConstructor, generateProxyConstructor, generateTimer, getBeanClassName, getBeanType, getLifecycleAspects, getLifecycleInstance, getLifecycleMethods, getViewClassName, isProxy, isRemote, toString
 
Methods inherited from class com.caucho.java.gen.GenClass
addImport, generate, generateTopComment, getFullClassName, getPackageName
 
Methods inherited from class com.caucho.java.gen.BaseClass
addComponent, addDependencyComponent, addInterfaceName, addMethod, createMethod, findMethod, generateClassContent, generateComponents, getClassName, setClassName, setStatic, setSuperClassName, setVisibility
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_contextClassName

protected java.lang.String _contextClassName
Constructor Detail

SessionGenerator

public SessionGenerator(java.lang.String ejbName,
                        AnnotatedType<X> beanType,
                        java.util.ArrayList<AnnotatedType<? super X>> localApi,
                        AnnotatedType<X> localBean,
                        java.util.ArrayList<AnnotatedType<? super X>> remoteApi,
                        java.lang.String beanTypeName)
Method Detail

toFullClassName

public static java.lang.String toFullClassName(java.lang.String ejbName,
                                               java.lang.String className,
                                               java.lang.String beanType)

isStateless

public boolean isStateless()

hasNoInterfaceView

public boolean hasNoInterfaceView()

getLocalApi

public java.util.ArrayList<AnnotatedType<? super X>> getLocalApi()
Returns the local API list.


getLocalBean

public AnnotatedType<X> getLocalBean()

getRemoteApi

public java.util.ArrayList<AnnotatedType<? super X>> getRemoteApi()
Returns the remote API list.


getAnnotatedMethods

protected java.util.ArrayList<AnnotatedMethod<? super X>> getAnnotatedMethods()
Returns the merged annotated methods


getMethods

public java.util.ArrayList<AspectGenerator<X>> getMethods()
Returns the introspected methods

Overrides:
getMethods in class BeanGenerator<X>

introspect

public void introspect()
Introspects the bean.

Overrides:
introspect in class BeanGenerator<X>

addBusinessMethod

protected void addBusinessMethod(AnnotatedMethod<? super X> method)

addPostConstructMethod

protected void addPostConstructMethod(AnnotatedMethod<? super X> method)

addPreDestroyMethod

protected void addPreDestroyMethod(AnnotatedMethod<? super X> method)

addNonBusinessMethod

protected void addNonBusinessMethod(AnnotatedMethod<? super X> method)

addScheduledMethod

protected void addScheduledMethod(AnnotatedMethod<? super X> method)

introspectLocalDefault

protected AnnotatedType<? super X> introspectLocalDefault()

generateContentImpl

protected void generateContentImpl(JavaWriter out,
                                   java.util.HashMap<java.lang.String,java.lang.Object> map)
                            throws java.io.IOException
Throws:
java.io.IOException

generatePostConstruct

protected void generatePostConstruct(JavaWriter out,
                                     java.util.HashMap<java.lang.String,java.lang.Object> map)
                              throws java.io.IOException
Overrides:
generatePostConstruct in class BeanGenerator<X>
Throws:
java.io.IOException

getScheduledAspectBeanFactory

protected AspectBeanFactory<X> getScheduledAspectBeanFactory()

isTimerSupported

protected abstract boolean isTimerSupported()

getAspectBeanFactory

protected abstract AspectBeanFactory<X> getAspectBeanFactory()
Specified by:
getAspectBeanFactory in class BeanGenerator<X>

getLifecycleAspectFactory

protected AspectBeanFactory<X> getLifecycleAspectFactory()
Overrides:
getLifecycleAspectFactory in class BeanGenerator<X>

isBusinessMethod

public static boolean isBusinessMethod(java.lang.reflect.Method method)