Package org.apache.cxf.interceptor.transform

Examples of org.apache.cxf.interceptor.transform.TransformOutInterceptor


    public void testPostBookTransform() throws Exception {
          
        String address = "http://localhost:" + PORT
                         + "/test/v1/rest-transform/bookstore/books";
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        out.setOutTransformElements(
            Collections.singletonMap("{http://www.example.org/books}*",
                                     "{http://www.example.org/super-books}*"));
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> map = new HashMap<String, String>();
View Full Code Here


        BookSoapService service =
            new BookSoapService(new URL(wsdlAddress),
                                new QName("http://books.com", "BookService"));
        BookStoreJaxrsJaxws store = service.getBookPort();
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        Map<String, String> mapOut = new HashMap<String, String>();
        // Book content (id, name) is unqualified, thus the following works
        // because JAXB will report
        // - {http://jaxws.jaxrs.systest.cxf.apache.org/}Book
        // - id
        // - name
        // and only the qualified top-level Book tag gets matched by the following
        // mapping
        mapOut.put("{http://jaxws.jaxrs.systest.cxf.apache.org/}*", "*");
        out.setOutTransformElements(mapOut);
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> mapIn = new HashMap<String, String>();
        // mapIn.put("*", "{http://jaxws.jaxrs.systest.cxf.apache.org/}*");
        // won't work for a case where a totally unqualified getBookResponse needs to be
View Full Code Here

    public void testPostBookTransform() throws Exception {
          
        String address = "http://localhost:" + PORT
                         + "/test/v1/rest-transform/bookstore/books";
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        out.setOutTransformElements(
            Collections.singletonMap("{http://www.example.org/books}*",
                                     "{http://www.example.org/super-books}*"));
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> map = new HashMap<String, String>();
View Full Code Here

        BookSoapService service =
            new BookSoapService(new URL(wsdlAddress),
                                new QName("http://books.com", "BookService"));
        BookStoreJaxrsJaxws store = service.getBookPort();
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        Map<String, String> mapOut = new HashMap<String, String>();
        // Book content (id, name) is unqualified, thus the following works
        // because JAXB will report
        // - {http://jaxws.jaxrs.systest.cxf.apache.org/}Book
        // - id
        // - name
        // and only the qualified top-level Book tag gets matched by the following
        // mapping
        mapOut.put("{http://jaxws.jaxrs.systest.cxf.apache.org/}*", "*");
        out.setOutTransformElements(mapOut);
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> mapIn = new HashMap<String, String>();
        // mapIn.put("*", "{http://jaxws.jaxrs.systest.cxf.apache.org/}*");
        // won't work for a case where a totally unqualified getBookResponse needs to be
View Full Code Here

  public void handleMessage(Message message) throws Fault {
    log.warn("Configuring interceptor");
    Map<String, String> appendElements = new HashMap<String, String>();
    appendElements.put("{http://schemas.xmlsoap.org/soap/envelope/}Body", "{http://schemas.xmlsoap.org/soap/envelope/}Header=");
    TransformOutInterceptor interceptor = new TransformOutInterceptor();
    interceptor.setOutAppendElements(appendElements);
    message.getInterceptorChain().add(interceptor);

    Map<String, String> envMap = new HashMap<String, String>();
    envMap.put( "env" , "http://schemas.xmlsoap.org/soap/envelope/");
    Map<String, String> nsMap = new HashMap<String, String>();
View Full Code Here

    public void testPostBookTransform() throws Exception {
          
        String address = "http://localhost:" + PORT
                         + "/test/v1/rest-transform/bookstore/books";
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        out.setOutTransformElements(
            Collections.singletonMap("{http://www.example.org/books}*",
                                     "{http://www.example.org/super-books}*"));
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> map = new HashMap<String, String>();
View Full Code Here

        BookSoapService service =
            new BookSoapService(new URL(wsdlAddress),
                                new QName("http://books.com", "BookService"));
        BookStoreJaxrsJaxws store = service.getBookPort();
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        Map<String, String> mapOut = new HashMap<String, String>();
        // Book content (id, name) is unqualified, thus the following works
        // because JAXB will report
        // - {http://jaxws.jaxrs.systest.cxf.apache.org/}Book
        // - id
        // - name
        // and only the qualified top-level Book tag gets matched by the following
        // mapping
        mapOut.put("{http://jaxws.jaxrs.systest.cxf.apache.org/}*", "*");
        out.setOutTransformElements(mapOut);
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> mapIn = new HashMap<String, String>();
        // mapIn.put("*", "{http://jaxws.jaxrs.systest.cxf.apache.org/}*");
        // won't work for a case where a totally unqualified getBookResponse needs to be
View Full Code Here

    public void testPostBookTransform() throws Exception {
          
        String address = "http://localhost:" + PORT
                         + "/test/v1/rest-transform/bookstore/books";
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        out.setOutTransformElements(
            Collections.singletonMap("{http://www.example.org/books}*",
                                     "{http://www.example.org/super-books}*"));
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> map = new HashMap<String, String>();
View Full Code Here

        BookSoapService service =
            new BookSoapService(new URL(wsdlAddress),
                                new QName("http://books.com", "BookService"));
        BookStoreJaxrsJaxws store = service.getBookPort();
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        Map<String, String> mapOut = new HashMap<String, String>();
        // Book content (id, name) is unqualified, thus the following works
        // because JAXB will report
        // - {http://jaxws.jaxrs.systest.cxf.apache.org/}Book
        // - id
        // - name
        // and only the qualified top-level Book tag gets matched by the following
        // mapping
        mapOut.put("{http://jaxws.jaxrs.systest.cxf.apache.org/}*", "*");
        out.setOutTransformElements(mapOut);
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> mapIn = new HashMap<String, String>();
        // mapIn.put("*", "{http://jaxws.jaxrs.systest.cxf.apache.org/}*");
        // won't work for a case where a totally unqualified getBookResponse needs to be
View Full Code Here

    public void testPostBookTransform() throws Exception {
          
        String address = "http://localhost:" + PORT
                         + "/test/v1/rest-transform/bookstore/books";
       
        TransformOutInterceptor out =  new TransformOutInterceptor();
        out.setOutTransformElements(
            Collections.singletonMap("{http://www.example.org/books}*",
                                     "{http://www.example.org/super-books}*"));
       
        TransformInInterceptor in =  new TransformInInterceptor();
        Map<String, String> map = new HashMap<String, String>();
View Full Code Here

TOP

Related Classes of org.apache.cxf.interceptor.transform.TransformOutInterceptor

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.