FileDocCategorySizeDatePackage
EJBProxyFactory.javaAPI DocJBoss 4.2.14636Fri Jul 13 20:53:58 BST 2007org.jboss.ejb3

EJBProxyFactory

public interface EJBProxyFactory implements org.jboss.ejb.GenericEntityObjectFactory, ContainerPlugin
This is an interface for Container plugins. Implementations of this interface are responsible for receiving remote invocations of EJB's and to forward these requests to the Container it is being used with.

It is responsible for providing any EJBObject and EJBHome implementations (which may be statically or dynamically created).

Before forwarding a call to the container it must call Thread.setContextClassLoader() with the classloader of the container. It must also handle any propagated transaction and security contexts properly. It may acquire the TransactionManager from JNDI.

see
Container
author
Rickard �berg
author
Marc Fleury
version
$Revision: 60233 $

20011219 marc fleury:

  • Moved from typed return to Object to allow for optimizations in creation
  • Per Dain Sundstrom requests removed the Remote Exception.
  • The Container Invoker is going to be replaced by the ProxyFactory *

Fields Summary
Constructors Summary
Methods Summary
public java.lang.ObjectgetEJBHome()
This method is called whenever the EJBHome implementation for this container is needed.

return
An implementation of the home interface for this container.

public javax.ejb.EJBMetaDatagetEJBMetaData()
This method is called whenever the metadata for this container is needed.

return
An implementation of the EJBMetaData interface.

public java.util.CollectiongetEntityCollection(java.util.Collection en)
This method is called whenever a collection of EJBObjects for a collection of primary keys is needed.

param
en Enumeration of primary keys.
return
A collection of EJBObjects implementing the remote interface for this container.

public java.lang.ObjectgetEntityEJBObject(java.lang.Object id)
This method is called whenever an EJBObject implementation for an entitybean is needed.

param
id The primary key of the entity.
return
An implementation of the remote interface for this container.

public java.lang.ObjectgetStatefulSessionEJBObject(java.lang.Object id)
This method is called whenever an EJBObject implementation for a stateful session bean is needed.

param
id The id of the session.
return
An implementation of the remote interface for this container.

public java.lang.ObjectgetStatelessSessionEJBObject()
This method is called whenever an EJBObject implementation for a stateless session bean is needed.

return
An implementation of the remote interface for this container.

public booleanisIdentical(Container container, org.jboss.invocation.Invocation mi)
Protocol specific isIdentical implementation

param
container the container
param
mi the invocation
return
true when identical, false otherwise

public voidsetInvokerBinding(java.lang.String binding)
Set the invoker jndi binding

public voidsetInvokerMetaData(org.jboss.metadata.InvokerProxyBindingMetaData imd)
Set the invoker meta data so that the ProxyFactory can initialize properly