Examples of createProxy()


Examples of org.apache.tuscany.sca.core.invocation.JDKProxyFactory.createProxy()

        JDKProxyFactory proxyService = new JDKProxyFactory();
             
        Class<?> proxyInterface = bundle.loadClass(interfaceClass.getName());
               

        Object proxy = proxyService.createProxy(proxyInterface, wire);
      
           
        bundleContext.registerService(proxyInterface.getName(), proxy, targetProperties);
           
       
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.ProxyFactory.createProxy()

                    RootResourceClassGenerator.generateRootResourceClass(interfaze,
                                                                         path,
                                                                         requestMediaType,
                                                                         responseMediaType);
                ProxyFactory proxyFactory = ExtensibleProxyFactory.getInstance(extensionPoints);
                Object proxy = proxyFactory.createProxy(interfaze, endpoint);
                RootResourceClassGenerator.injectProxy(cls, proxy);
                return cls;
            } catch (Exception e) {
                throw new ServiceRuntimeException(e);
            }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.ProxyFactory.createProxy()

                                        serviceInterface);
        } catch (Exception e) {
            throw new ServiceRuntimeException(e);
        }

        return proxyFactory.createProxy(serviceInterface, epr);
    }

    private RuntimeEndpointReference createEndpointReference(JavaInterfaceFactory javaInterfaceFactory,
                                                             CompositeContext compositeContext,
                                                             AssemblyFactory assemblyFactory,
View Full Code Here

Examples of org.apache.tuscany.spi.wire.WireService.createProxy()

        EasyMock.expect(inboundWire.getServiceContract()).andReturn(contract).anyTimes();
        EasyMock.replay(inboundWire);

        //Create mocked WireService, for ServiceExtension.getServiceInstance()
        WireService wireService = EasyMock.createNiceMock(WireService.class);
        wireService.createProxy(EasyMock.isA(InboundWire.class));
        EasyMock.expectLastCall().andReturn(new GreeterImpl()).anyTimes();
        EasyMock.replay(wireService);

        CeltixService celtixService = new CeltixService("name", Greeter.class, null, wireService, wsBinding, bus, null);
        //Not sure how InboundWire is set to CeltixService, is the following way correct?
View Full Code Here

Examples of org.hibernate.persister.entity.EntityPersister.createProxy()

          boolean eager,
          boolean nullable) throws HibernateException {
    errorIfClosed();
    EntityPersister persister = getFactory().getEntityPersister(entityName);
    if ( !eager && persister.hasProxy() ) {
      return persister.createProxy(id, this);
    }
    Object loaded = temporaryPersistenceContext.getEntity( new EntityKey(id, persister, EntityMode.POJO) );
    //TODO: if not loaded, throw an exception
    return loaded==null ? get( entityName, id ) : loaded;
  }
View Full Code Here

Examples of org.jboss.as.ee.component.ComponentViewInstance.createProxy()

        }
        if(viewServices.containsKey(businessInterfaceType.getName())) {
            final ServiceController<?> serviceController = CurrentServiceRegistry.getServiceRegistry().getRequiredService(viewServices.get(businessInterfaceType.getName()));
            final ComponentView view = (ComponentView)serviceController.getValue();
            final ComponentViewInstance instance = view.createInstance();
            return (S) instance.createProxy();
        } else {
            throw new IllegalArgumentException("View of type " + businessInterfaceType + " not found on bean ");
        }
    }
View Full Code Here

Examples of org.jboss.ejb3.proxy.reflect.ReflectProxyFactory.createProxy()

            InvocationHandler invocationHandler = new SingletonBeanRemoteInvocationHandler(containerRegistryKey,
                  defaultInvokerLocatorURL, clientInterceptors, businessRemote);

            // time to create a proxy
            Object proxy = proxyFactory.createProxy(new Class<?>[]
            {businessRemoteIntf}, invocationHandler);

            // bind to jndi

            String jndiName = jndiNameResolver.resolveJNDIName(sessionBean, businessRemote);
View Full Code Here

Examples of org.jboss.ejb3.proxy.spi.factory.ProxyFactory.createProxy()

            InvocationHandler invocationHandler = new SingletonBeanRemoteInvocationHandler(containerRegistryKey,
                  defaultInvokerLocatorURL, clientInterceptors, businessRemote);

            // time to create a proxy
            Object proxy = proxyFactory.createProxy(new Class<?>[]
            {businessRemoteIntf}, invocationHandler);

            // bind to jndi

            String jndiName = jndiNameResolver.resolveJNDIName(sessionBean, businessRemote);
View Full Code Here

Examples of org.jboss.invocation.InvokerHA.createProxy()

    */
   public Invoker createDateTimeTellerProxy(int serverIndex, Class<? extends LoadBalancePolicy> policyClass) throws Exception
   {
      InvokerHA server = replicants.get(serverIndex);
      log.debug("replicants: " + replicants);
      return server.createProxy(dateTimeTellerON, policyClass.newInstance(), "UnitTestPartition/DateTimeTellerMBean");
   }
  
   /**
    * Create a proxy to system time teller bean.
    *
 
View Full Code Here

Examples of org.jboss.proxy.GenericProxyFactory.createProxy()

     ArrayList interceptorClasses = new ArrayList();
     interceptorClasses.add(ClientMethodInterceptor.class);
     interceptorClasses.add(InvokerInterceptor.class);
     ClassLoader loader = Thread.currentThread().getContextClassLoader();
     GenericProxyFactory proxyFactory = new GenericProxyFactory();
     theProxy = proxyFactory.createProxy(cacheID, targetName,
        delegateInvoker, jndiName, proxyBindingName, interceptorClasses,
        loader, ifaces);
     log.debug("Created proxy for invoker=" + jmxInvokerName
        + ", targetName=" + targetName + ", nameHash=" + nameHash);
   }
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.