Package org.apache.cxf.interceptor

Examples of org.apache.cxf.interceptor.LoggingOutInterceptor


        String configurationFile = "jettyBasicAuthServer.xml";
        URL configure =
            JettyBasicAuthServer.class.getResource(configurationFile);
        Bus bus = new SpringBusFactory().createBus(configure, true);
        bus.getInInterceptors().add(new LoggingInInterceptor());
        bus.getOutInterceptors().add(new LoggingOutInterceptor());
        SpringBusFactory.setDefaultBus(bus);
        setBus(bus);

        GreeterImpl implementor = new GreeterImpl();
        Endpoint.publish(ADDRESS, implementor);
View Full Code Here


        JaxWsProxyFactoryBean proxyFactory = new JaxWsProxyFactoryBean();
        proxyFactory.setDataBinding(aegisBinding);
        proxyFactory.setServiceClass(SportsService.class);
        proxyFactory.setAddress("http://localhost:" + PORT + "/jaxwsAndAegisSports");
        proxyFactory.getInInterceptors().add(new LoggingInInterceptor());
        proxyFactory.getOutInterceptors().add(new LoggingOutInterceptor());
        SportsService service = (SportsService) proxyFactory.create();
        int ret = service.getGenericPair(new Pair<Integer, String>(111, "String"));
        assertEquals(111, ret);
    }
View Full Code Here

        JaxWsProxyFactoryBean proxyFactory = new JaxWsProxyFactoryBean();
        proxyFactory.setDataBinding(aegisBinding);
        proxyFactory.setServiceClass(SportsService.class);
        proxyFactory.setAddress("http://localhost:" + PORT + "/jaxwsAndAegisSports");
        proxyFactory.getInInterceptors().add(new LoggingInInterceptor());
        proxyFactory.getOutInterceptors().add(new LoggingOutInterceptor());
        SportsService service = (SportsService) proxyFactory.create();
        int ret = service.getQualifiedPair(new Pair<Integer, String>(111, "ffang"));
        assertEquals(111, ret);
    }
View Full Code Here

                                                 + PORT1 + "/ArrayService?wsdl"));

        String[] values = new String[] {"foobar", "something" };
        List<String> list = Arrays.asList(values);
       
        client.getOutInterceptors().add(new LoggingOutInterceptor());
        client.getInInterceptors().add(new LoggingInInterceptor());
        client.invoke("init", list);
    }
View Full Code Here

       
        URL wsdl = SecurityPolicyTest.class.getResource("DoubleIt.wsdl");
       
        createStaticBus(SecurityPolicyTest.class.getResource("https_config.xml").toString())
            .getExtension(PolicyEngine.class).setEnabled(true);
        getStaticBus().getOutInterceptors().add(new LoggingOutInterceptor());
       
        EndpointImpl ep = (EndpointImpl)Endpoint.create(new DoubleItImpl());
        ep.setEndpointName(new QName("http://www.example.org/contract/DoubleIt", "DoubleItPortHttps"));
        ep.setWsdlLocation(wsdl.getPath());
        ep.setAddress(POLICY_HTTPS_ADDRESS);
View Full Code Here

            EndpointImpl jaxep = (EndpointImpl) javax.xml.ws.Endpoint.publish(address, implementor);
            Endpoint ep = jaxep.getServer().getEndpoint();
            ep.getInInterceptors().add(new TestMultipartMessageInterceptor());
            ep.getOutInterceptors().add(new TestAttachmentOutInterceptor());
            ep.getInInterceptors().add(new LoggingInInterceptor());
            ep.getOutInterceptors().add(new LoggingOutInterceptor());
            SOAPBinding jaxWsSoapBinding = (SOAPBinding) jaxep.getBinding();
            jaxWsSoapBinding.setMTOMEnabled(true);

        } catch (Exception e) {
            Thread.currentThread().interrupt();
View Full Code Here

            //jaxwsEndpoint.getBinding().getInInterceptors().add(new TestMultipartMessageInterceptor());
            jaxwsEndpoint.getBinding().getOutInterceptors().add(new TestAttachmentOutInterceptor());
        }
       
        jaxwsEndpoint.getBinding().getInInterceptors().add(new LoggingInInterceptor());
        jaxwsEndpoint.getBinding().getOutInterceptors().add(new LoggingOutInterceptor());

        Client client = new ClientImpl(bus, jaxwsEndpoint);
        InvocationHandler ih = new JaxWsClientProxy(client, jaxwsEndpoint.getJaxwsBinding());
        Object obj = Proxy
            .newProxyInstance(serviceEndpointInterface.getClassLoader(),
View Full Code Here

        Endpoint ep = Endpoint.create(implementor);

        URL wsdl = getClass().getResource("/wsdl_systest/cxf2006.wsdl");
        ((EndpointImpl)ep).setWsdlLocation(wsdl.toString());
        ((EndpointImpl)ep).getInInterceptors().add(new LoggingInInterceptor());
        ((EndpointImpl)ep).getOutInterceptors().add(new LoggingOutInterceptor());
        ep.publish(address);
    }
View Full Code Here

        java.io.PrintWriter pwin = new java.io.PrintWriter(swin);
        LoggingInInterceptor logIn = new LoggingInInterceptor(pwin);
       
        StringWriter swout = new java.io.StringWriter();
        java.io.PrintWriter pwout = new java.io.PrintWriter(swout);
        LoggingOutInterceptor logOut = new LoggingOutInterceptor(pwout);
       
       
        getBus().getInInterceptors().add(logIn);
        getBus().getOutInterceptors().add(logOut);
        SOAPServiceRPCLit service = new SOAPServiceRPCLit();
View Full Code Here

    protected ByteArrayOutputStream setupOutLogging() {
        ByteArrayOutputStream bos = new ByteArrayOutputStream();
        PrintWriter writer = new PrintWriter(bos, true);

        LoggingOutInterceptor out = new LoggingOutInterceptor(writer);
        this.bus.getOutInterceptors().add(out);

        return bos;
    }
View Full Code Here

TOP

Related Classes of org.apache.cxf.interceptor.LoggingOutInterceptor

Copyright © 2018 www.massapicom. 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.