Examples of StatefulSessionProxyFactory


Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

        
         // Find the Proxy Factory Key for this SFSB
         String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(this.getMetaData(), isLocal);

         // Lookup the Proxy Factory in the Object Store
         StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
               StatefulSessionProxyFactory.class);
        
         // Create a new EJB2.x Proxy
         Object proxy = proxyFactory.createProxyEjb2x((Serializable)newStatefulInvocation.getSessionId());
        
         InvocationResponse response = marshallResponse(statefulInvocation, proxy, newStatefulInvocation.getResponseContextInfo());
         if (newStatefulInvocation.getSessionId() != null)
            response.addAttachment(StatefulConstants.NEW_ID,
                    newStatefulInvocation.getSessionId());
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

        
         // Find the Proxy Factory Key for this SFSB
         String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(this.getMetaData(), isLocal);

         // Lookup the Proxy Factory in the Object Store
         StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
               StatefulSessionProxyFactory.class);
        
         // Create a new EJB2.x Proxy
         EJBObject proxy = (EJBObject)proxyFactory.createProxyEjb2x((Serializable)newStatefulInvocation.getId());
        
         StatefulHandleRemoteImpl handle = new StatefulHandleRemoteImpl(proxy);
         InvocationResponse response = marshallResponse(statefulInvocation, handle, null);
         return response;
      }
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

     
      // Find the Proxy Factory Key for this SFSB
      String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(this.getMetaData(), !isRemote);
     
      // Lookup the Proxy Factory in the Object Store
      StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
            StatefulSessionProxyFactory.class);
     
      // Create a new business proxy
      Object proxy = proxyFactory.createProxyBusiness((Serializable) ctx.getId(), businessInterface.getName());
     
      // Return the Proxy
      return proxy;

//      Collection<ProxyFactory> proxyFactories = this.proxyDeployer.getProxyFactories().values();
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

      Object factory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey);
     
      // Cast
      assert factory instanceof StatefulSessionProxyFactory : "Specified factory " + factory.getClass().getName() + " is not of type "
      + StatefulSessionProxyFactory.class.getName() + " as required by " + StatefulContainer.class.getName() + ", but was instead " + factory;
      StatefulSessionProxyFactory statefulFactory = null;
      statefulFactory = StatefulSessionProxyFactory.class.cast(factory);

      Object proxy = statefulFactory.createProxyEjb2x();

      return proxy;
   }
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

     
      // Find the Proxy Factory Key for this SFSB
      String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(this.getMetaData(), !isRemote);
     
      // Lookup the Proxy Factory in the Object Store
      StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
            StatefulSessionProxyFactory.class);
     
      // Create a new business proxy
      Object proxy = proxyFactory.createProxyBusiness((Serializable) ctx.getId(), businessInterface.getName());
     
      // Return the Proxy
      return proxy;

//      Collection<ProxyFactory> proxyFactories = this.proxyDeployer.getProxyFactories().values();
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

      return new StatefulBeanContext(this, construct());
   }
  
   public Object createProxyLocalEjb21(Object id, LocalBinding binding) throws Exception
   {
      StatefulSessionProxyFactory proxyFactory = (StatefulSessionProxyFactory)this.getProxyFactory(binding);
      return proxyFactory.createProxyEjb2x((Serializable)id);
   }
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

      return this.createProxyRemoteEjb21(id,binding);
   }

   public Object createProxyRemoteEjb21(Object id, RemoteBinding binding) throws Exception
   {
      StatefulSessionProxyFactory proxyFactory = (StatefulSessionProxyFactory)this.getProxyFactory(binding);
      return proxyFactory.createProxyEjb2x((Serializable)id);
   }
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

      Object factory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey);
     
      // Cast
      assert factory instanceof StatefulSessionProxyFactory : "Specified factory " + factory.getClass().getName() + " is not of type "
         + StatefulSessionProxyFactory.class.getName() + " as required by " + StatefulContainer.class.getName() + ", but was instead " + factory;
      StatefulSessionProxyFactory statefulFactory = null;
      statefulFactory = StatefulSessionProxyFactory.class.cast(factory);
     
      Serializable sessionId = createSession(method.getParameterTypes(), args);
      Object proxy = statefulFactory.createProxyEjb2x(sessionId);
     
      return proxy;
   }
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

         // Find the Proxy Factory Key for this SFSB
         String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(jndiName, smd, isLocal);

         // Lookup the Proxy Factory in the Object Store
         StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
               StatefulSessionProxyFactory.class);
        
         // Create a new EJB2.x Proxy
         Object proxy = proxyFactory.createProxyEjb2x((Serializable)newStatefulInvocation.getSessionId());
        
         InvocationResponse response = marshallResponse(statefulInvocation, proxy, newStatefulInvocation.getResponseContextInfo());
         if (newStatefulInvocation.getSessionId() != null)
            response.addAttachment(StatefulConstants.NEW_ID,
                    newStatefulInvocation.getSessionId());
View Full Code Here

Examples of org.jboss.ejb3.proxy.factory.session.stateful.StatefulSessionProxyFactory

        
         // Find the Proxy Factory Key for this SFSB
         String proxyFactoryKey = sfsbJndiRegistrar.getProxyFactoryRegistryKey(jndiName, smd, isLocal);

         // Lookup the Proxy Factory in the Object Store
         StatefulSessionProxyFactory proxyFactory = Ejb3RegistrarLocator.locateRegistrar().lookup(proxyFactoryKey,
               StatefulSessionProxyFactory.class);
        
         // Create a new EJB2.x Proxy
         EJBObject proxy = (EJBObject)proxyFactory.createProxyEjb2x((Serializable)newStatefulInvocation.getId());
        
         StatefulHandleRemoteImpl handle = new StatefulHandleRemoteImpl(proxy);
         InvocationResponse response = marshallResponse(statefulInvocation, handle, null);
         return response;
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.