org.ow2.jonas.lib.ejb21
Class JLocalHome

java.lang.Object
  extended by org.ow2.jonas.lib.ejb21.JLocalHome
All Implemented Interfaces:
EJBLocalHome
Direct Known Subclasses:
JEntityLocalHome, JSessionLocalHome

public abstract class JLocalHome
extends Object
implements EJBLocalHome

This class represents an EJBLocalHome It is shared between Sessions and Entities.

Author:
Philippe Durieux

Field Summary
protected  JFactory bf
           
protected  BeanDesc dd
           
protected static Map homeList
           
 
Constructor Summary
JLocalHome(BeanDesc dd, JFactory bf)
          Constructor for the base class of the specific generated Home object.
 
Method Summary
 void checkSecurity(EJBInvocation ejbInv)
          Check if the access to the bean is authorized
 String getJndiLocalName()
           
static JLocalHome getLocalHome(String beanName)
          Get JLocalHome by its name
 void postInvoke(RequestCtx rctx)
          postInvoke is called after any request.
 RequestCtx preInvoke(int txa)
          preInvoke is called before any request.
protected  void register()
          register this bean to JNDI (rebind) We register actually a Reference object.
abstract  void remove(Object primaryKey)
          Removes an EJB object identified by its primary key.
protected  void unregister()
          unregister this bean in JNDI (unbind)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dd

protected BeanDesc dd

bf

protected JFactory bf

homeList

protected static Map homeList
Constructor Detail

JLocalHome

public JLocalHome(BeanDesc dd,
                  JFactory bf)
Constructor for the base class of the specific generated Home object.

Parameters:
dd - The Bean Deployment Descriptor
bf - The Bean Factory
Method Detail

remove

public abstract void remove(Object primaryKey)
                     throws RemoveException
Removes an EJB object identified by its primary key.

Specified by:
remove in interface EJBLocalHome
Parameters:
primaryKey - The Primary Key
Throws:
RemoveException

getJndiLocalName

public String getJndiLocalName()
Returns:
The JNDI name

register

protected void register()
                 throws NamingException
register this bean to JNDI (rebind) We register actually a Reference object.

Throws:
NamingException

unregister

protected void unregister()
                   throws NamingException
unregister this bean in JNDI (unbind)

Throws:
NamingException

getLocalHome

public static JLocalHome getLocalHome(String beanName)
Get JLocalHome by its name

Parameters:
beanName - The Bean JNDI local Name
Returns:
The Bean LocalHome

preInvoke

public RequestCtx preInvoke(int txa)
preInvoke is called before any request.

Parameters:
txa - Transaction Attribute (Supports, Required, ...)
Returns:
A RequestCtx object
Throws:
EJBException

checkSecurity

public void checkSecurity(EJBInvocation ejbInv)
Check if the access to the bean is authorized

Parameters:
ejbInv - object containing security signature of the method, args of method, etc

postInvoke

public void postInvoke(RequestCtx rctx)
postInvoke is called after any request.

Parameters:
rctx - The RequestCtx that was returned at preInvoke()


Copyright © 2010 OW2 Consortium. All Rights Reserved.