Examples of Echo


Examples of org.codehaus.xfire.test.Echo

        factory.afterPropertiesSet();
       
        Class objectType = factory.getObjectType();
        assertTrue("object created by factory does not implement interface", Echo.class.isAssignableFrom(objectType));

        Echo obj = (Echo)factory.getObject();
        Object handler = Proxy.getInvocationHandler(obj);
        Class handlerClass = handler.getClass();
        assertTrue("factory created own proxy: " + handlerClass, XFireProxy.class.isAssignableFrom(handlerClass));       
        XFireProxy fireProxy = (XFireProxy)handler;
        checkAuth(fireProxy, null, null);
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

        factory.afterPropertiesSet();
       
        Class objectType = factory.getObjectType();
        assertTrue("object created by factory does not implement interface", Echo.class.isAssignableFrom(objectType));
   
        Echo obj = (Echo)factory.getObject();
        Object handler = Proxy.getInvocationHandler(obj);
        Class handlerClass = handler.getClass();
        assertTrue("factory created own proxy: " + handlerClass, XFireProxy.class.isAssignableFrom(handlerClass));       
        XFireProxy fireProxy = (XFireProxy)handler;
        checkAuth(fireProxy, null, null);
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

        factory.setLookupServiceOnStartup(false);
        factory.afterPropertiesSet();
       
        Class objectType = factory.getObjectType();
        assertTrue("object created by factory does not implement interface", Echo.class.isAssignableFrom(objectType));
        Echo obj = (Echo)factory.getObject();
        Object handler = Proxy.getInvocationHandler(obj);
        Class handlerClass = handler.getClass();
        assertTrue("factory did not create own proxy: " + handlerClass, AopProxy.class.isAssignableFrom(handlerClass));
       
        assertEquals("Wrong uninit toString() for proxy",
                     "Un-initialized XFire client proxy for: interface org.codehaus.xfire.test.Echo at: " + serviceURL,
                     obj.toString());
    }
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

        String expectedPassword = "hoeben";
        factory.setUsername(expectedUsername);
        factory.setPassword(expectedPassword);
        factory.afterPropertiesSet();

        Echo obj = (Echo)factory.getObject();
       
        XFireProxy handler = (XFireProxy)Proxy.getInvocationHandler(obj);
        checkAuth(handler, expectedUsername, expectedPassword);
    }
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

        factory = new XFireClientFactoryBean();
        factory.setServiceInterface(Echo.class);
        factory.setWsdlDocumentUrl("http://localhost:8191/Echo?wsdl");
        factory.afterPropertiesSet();
       
        Echo echo = (Echo) factory.getObject();
        assertEquals("hi", echo.echo("hi"));
       
        server.stop();
    }
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

        factory = new XFireClientFactoryBean();
        factory.setServiceInterface(Echo.class);
        factory.setWsdlDocumentUrl("http://localhost:8191/Echo?wsdl");
        factory.afterPropertiesSet();
       
        Echo echo = (Echo) factory.getObject();
        assertEquals("hi", echo.echo("hi"));
       
        server.stop();
    }
View Full Code Here

Examples of org.codehaus.xfire.test.Echo

   
    public void testClient()
        throws Exception
    {
        XFireProxyFactory xpf = new XFireProxyFactory(getXFire());
        Echo echo = (Echo) xpf.create(service, "xfire.local://Echo");
       
        assertEquals("hi", echo.echo("hi"));
    }
View Full Code Here

Examples of org.fusesource.restygwt.client.basic.Echo

        doEchoRequest(request, response);
    }

    @SuppressWarnings("unchecked")
    private void doEchoRequest(HttpServletRequest request, HttpServletResponse response) throws IOException {
        Echo echo = new Echo();
        echo.path = request.getPathInfo();

        echo.params = new HashMap<String, String>();
        ObjectMapper mapper = new ObjectMapper();
        for ( Map.Entry<String, String[]> entry:  (Set<Map.Entry<String, String[]>>) request.getParameterMap().entrySet() ){
View Full Code Here

Examples of org.jboss.as.test.integration.osgi.xservice.api.Echo

    static final Logger log = Logger.getLogger(TargetBundleActivator.class);

    @Override
    public void start(final BundleContext context) throws Exception {
        context.registerService(Echo.class.getName(), new Echo() {
            public String echo(String message) {
                log.infof("Echo: %s", message);
                return message;
            }
        }, null);
View Full Code Here

Examples of org.jboss.as.test.integration.osgi.xservice.api.Echo

   @Override
   public void start(final BundleContext context) throws Exception
   {
      log.infof("Echo Loader: %s", Echo.class.getClassLoader());
      ServiceReference sref = context.getServiceReference(Echo.class.getName());
      Echo service = (Echo)context.getService(sref);
      String result = service.echo("hello world");
      context.registerService(StringBuffer.class.getName(), new StringBuffer(result), null);
   }
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.