org.jboss.ejb.plugins.jrmp.interfaces
Class BeanProxy

java.lang.Object
  |
  +--org.jboss.ejb.plugins.jrmp.interfaces.GenericProxy
        |
        +--org.jboss.ejb.plugins.jrmp.interfaces.BeanProxy
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable
Direct Known Subclasses:
EntityProxy, StatefulSessionProxy, StatelessSessionProxy

public abstract class BeanProxy
extends GenericProxy

An abstract base proxy class from which all bean proxys extend from.

Version:
$Revision: 1.1.4.3 $
Author:
Jason Dillon <jason@planet57.com>
See Also:
Serialized Form

Field Summary
protected static java.lang.reflect.Method GET_EJB_HOME
          EJBObject.getEJBHome() method reference.
protected static java.lang.reflect.Method GET_HANDLE
          EJBObject.getHandle() method reference.
protected static java.lang.reflect.Method GET_PRIMARY_KEY
          EJBObject.getPrimaryKey() method reference.
protected static java.lang.reflect.Method IS_IDENTICAL
          EJBObject.isIdentical(javax.ejb.EJBObject) method reference.
 
Fields inherited from class org.jboss.ejb.plugins.jrmp.interfaces.GenericProxy
container, EMPTY_ARGS, EQUALS, HASH_CODE, initialContextHandle, name, optimize, TO_STRING, tpcFactory
 
Constructor Summary
  BeanProxy()
          No-argument constructor for externalization.
protected BeanProxy(java.lang.String name, ContainerRemote container, boolean optimize)
          Initialze.
 
Method Summary
protected  javax.ejb.EJBHome getEJBHome()
          Get a EJBHome reference for this proxy.
protected  java.lang.Boolean isIdentical(java.lang.Object a, java.lang.Object b)
          Test the identitiy of an EJBObject.
 
Methods inherited from class org.jboss.ejb.plugins.jrmp.interfaces.GenericProxy
addLocal, createInitialContext, createMarshalledObject, getCredential, getPrincipal, getTransaction, getTransactionPropagationContext, invokeContainer, isLocal, readExternal, removeLocal, setTPCFactory, setTransactionManager, writeExternal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GET_PRIMARY_KEY

protected static final java.lang.reflect.Method GET_PRIMARY_KEY
EJBObject.getPrimaryKey() method reference.

GET_HANDLE

protected static final java.lang.reflect.Method GET_HANDLE
EJBObject.getHandle() method reference.

GET_EJB_HOME

protected static final java.lang.reflect.Method GET_EJB_HOME
EJBObject.getEJBHome() method reference.

IS_IDENTICAL

protected static final java.lang.reflect.Method IS_IDENTICAL
EJBObject.isIdentical(javax.ejb.EJBObject) method reference.
Constructor Detail

BeanProxy

public BeanProxy()
No-argument constructor for externalization.

BeanProxy

protected BeanProxy(java.lang.String name,
                    ContainerRemote container,
                    boolean optimize)
Initialze.
Parameters:
name - The JNDI name of the container that we proxy for.
container - The remote interface of the invoker for which this is a proxy for.
optimize - True if the proxy will attempt to optimize VM-local calls.
Method Detail

getEJBHome

protected javax.ejb.EJBHome getEJBHome()
                                throws javax.naming.NamingException
Get a EJBHome reference for this proxy.
Returns:
EJBHome reference.
Throws:
javax.naming.NamingException - Failed to create InitalContext or lookup EJBHome reference.

isIdentical

protected java.lang.Boolean isIdentical(java.lang.Object a,
                                        java.lang.Object b)
                                 throws java.rmi.RemoteException
Test the identitiy of an EJBObject.
Parameters:
a - EJBObject.
b - Object to test identity with.
Returns:
True if objects are identical.
Throws:
java.rmi.RemoteException - Failed to get primary key.
java.lang.ClassCastException - Not an EJBObject instance.


Copyright © 2000 The JBoss Organization. All Rights Reserved.