com.bm.creators
Class SessionBeanFactory<T>

java.lang.Object
  extended by com.bm.creators.SessionBeanFactory<T>
Type Parameters:
T - - the type of the session bean to create (class name)

public final class SessionBeanFactory<T>
extends java.lang.Object

This class will create session bean instances without an application server. The dependency injection is done here

Since:
18.09.2005
Author:
Daniel Wiese

Constructor Summary
SessionBeanFactory(javax.persistence.EntityManager em)
          Default constructor.
 
Method Summary
 T createSessionBean(java.lang.Class<T> toCreate)
          Factory method to create stateless session beans.
 com.bm.ejb3guice.inject.Injector getInjector(java.lang.Class<T> toCreate, com.bm.ejb3guice.inject.CreationListner creationListener)
          Creates the injector to create session beans and inject fields
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SessionBeanFactory

@Inject
public SessionBeanFactory(javax.persistence.EntityManager em)
Default constructor.

Parameters:
em - - the current entity manager
Method Detail

createSessionBean

public T createSessionBean(java.lang.Class<T> toCreate)
Factory method to create stateless session beans.

Parameters:
toCreate - - the class to create
Returns:
- the created session bean class for local usage
Since:
18.09.2005

getInjector

public com.bm.ejb3guice.inject.Injector getInjector(java.lang.Class<T> toCreate,
                                                    com.bm.ejb3guice.inject.CreationListner creationListener)
Creates the injector to create session beans and inject fields

Parameters:
toCreate - - the class to create
Returns:
- the injector


Copyright © 2008. All Rights Reserved.