Search in sources :

Example 66 with EJBHome

use of javax.ejb.EJBHome in project tomee by apache.

the class UnknownEjbObjectTests method test04_getEjbHome.

public void test04_getEjbHome() {
    try {
        final EJBHome home = ejbObject.getEJBHome();
        assertNotNull("The EJBHome is null", home);
    } catch (final Exception e) {
        fail("Received Exception " + e.getClass() + " : " + e.getMessage());
    }
}
Also used : EJBHome(javax.ejb.EJBHome) ObjectNotFoundException(javax.ejb.ObjectNotFoundException)

Example 67 with EJBHome

use of javax.ejb.EJBHome in project wildfly by wildfly.

the class HandleDelegateImpl method readEJBHome.

public EJBHome readEJBHome(final ObjectInputStream oistream) throws IOException, ClassNotFoundException {
    final Object ejbHome = proxy.read(oistream);
    reconnect(ejbHome);
    return (EJBHome) PortableRemoteObject.narrow(ejbHome, EJBHome.class);
}
Also used : EJBHome(javax.ejb.EJBHome) EJBObject(javax.ejb.EJBObject) PortableRemoteObject(javax.rmi.PortableRemoteObject)

Aggregations

EJBHome (javax.ejb.EJBHome)67 RemoteException (java.rmi.RemoteException)15 EJBObject (javax.ejb.EJBObject)11 InitialContext (javax.naming.InitialContext)10 HomeHandle (javax.ejb.HomeHandle)8 ObjectNotFoundException (javax.ejb.ObjectNotFoundException)7 EJBException (javax.ejb.EJBException)6 ByteArrayInputStream (java.io.ByteArrayInputStream)3 ByteArrayOutputStream (java.io.ByteArrayOutputStream)3 ObjectInputStream (java.io.ObjectInputStream)3 ObjectOutputStream (java.io.ObjectOutputStream)3 Method (java.lang.reflect.Method)3 MarshalledObject (java.rmi.MarshalledObject)3 EJBLocalHome (javax.ejb.EJBLocalHome)2 EJBMetaData (javax.ejb.EJBMetaData)2 Handle (javax.ejb.Handle)2 RemoveException (javax.ejb.RemoveException)2 PortableRemoteObject (javax.rmi.PortableRemoteObject)2 Test (org.junit.Test)2 InvalidServiceException (com.ing.ifsa.internal.exceptions.InvalidServiceException)1