Package com.sun.ejb.containers
Class EJBLocalObjectImpl
- java.lang.Object
-
- com.sun.ejb.containers.EJBLocalRemoteObject
-
- com.sun.ejb.containers.EJBLocalObjectImpl
-
- All Implemented Interfaces:
IndirectlySerializable
,jakarta.ejb.EJBLocalObject
- Direct Known Subclasses:
EJBLocalObjectInvocationHandler
public abstract class EJBLocalObjectImpl extends EJBLocalRemoteObject implements jakarta.ejb.EJBLocalObject, IndirectlySerializable
Implementation of the EJBLocalObject interface. This is NOT serializable to prevent local references from leaving the JVM. It is extended by the generated concrete type-specific EJBLocalObject implementation (e.g. Hello_EJBLocalObject).- Author:
- Mahesh Kannan
-
-
Field Summary
-
Fields inherited from class com.sun.ejb.containers.EJBLocalRemoteObject
container, debug, primaryKey
-
-
Constructor Summary
Constructors Constructor Description EJBLocalObjectImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
getClientObject()
Get the client object corresponding to an EJBLocalObjectImpl.jakarta.ejb.EJBLocalHome
getEJBLocalHome()
Object
getPrimaryKey()
SerializableObjectFactory
getSerializableObjectFactory()
Called from EJBUtils.EJBObjectOutputStream.replaceObjectboolean
isIdentical(jakarta.ejb.EJBLocalObject other)
void
remove()
static EJBLocalObjectImpl
toEJBLocalObjectImpl(jakarta.ejb.EJBLocalObject localObj)
Since EJBLocalObject might be a dynamic proxy, the container can't assume it can cast from EJBLocalObject to EJBLocalObjectImpl.-
Methods inherited from class com.sun.ejb.containers.EJBLocalRemoteObject
getContainer, getSfsbClientVersion, setSfsbClientVersion
-
-
-
-
Method Detail
-
getClientObject
public Object getClientObject()
Get the client object corresponding to an EJBLocalObjectImpl. Users of this class cannot assume they can cast an EJBLocalObjectImpl to the object that the client uses, and vice-versa. This is overridden in the InvocationHandler. Only applicable for local home view.
-
toEJBLocalObjectImpl
public static EJBLocalObjectImpl toEJBLocalObjectImpl(jakarta.ejb.EJBLocalObject localObj)
Since EJBLocalObject might be a dynamic proxy, the container can't assume it can cast from EJBLocalObject to EJBLocalObjectImpl. This convenience method is used to hide the logic behind the translation from an client-side EJBLocalObject to the corresponding EJBLocalObjectImpl. In the case of a proxy, the invocation handler is the EJBLocalObjectImpl. Otherwise, the argument is returned as is. NOTE : To translate in the other direction, use EJBLocalObjectImpl.getEJBLocalObject()
-
getEJBLocalHome
public jakarta.ejb.EJBLocalHome getEJBLocalHome() throws jakarta.ejb.EJBException
- Specified by:
getEJBLocalHome
in interfacejakarta.ejb.EJBLocalObject
- Throws:
jakarta.ejb.EJBException
-
remove
public void remove() throws jakarta.ejb.RemoveException, jakarta.ejb.EJBException
- Specified by:
remove
in interfacejakarta.ejb.EJBLocalObject
- Throws:
jakarta.ejb.RemoveException
jakarta.ejb.EJBException
-
getPrimaryKey
public Object getPrimaryKey() throws jakarta.ejb.EJBException
- Specified by:
getPrimaryKey
in interfacejakarta.ejb.EJBLocalObject
- Throws:
jakarta.ejb.EJBException
-
isIdentical
public boolean isIdentical(jakarta.ejb.EJBLocalObject other) throws jakarta.ejb.EJBException
- Specified by:
isIdentical
in interfacejakarta.ejb.EJBLocalObject
- Throws:
jakarta.ejb.EJBException
-
getSerializableObjectFactory
public SerializableObjectFactory getSerializableObjectFactory()
Called from EJBUtils.EJBObjectOutputStream.replaceObject- Specified by:
getSerializableObjectFactory
in interfaceIndirectlySerializable
-
-