Search in sources :

Example 6 with ElementNameStrategy

use of org.apache.camel.dataformat.soap.name.ElementNameStrategy in project camel by apache.

the class SoapMarshalTest method createDataFormat.

/**
     * Create data format by using the constructor
     */
protected SoapJaxbDataFormat createDataFormat() {
    String jaxbPackage = GetCustomersByName.class.getPackage().getName();
    ElementNameStrategy elStrat = new TypeNameStrategy();
    return new SoapJaxbDataFormat(jaxbPackage, elStrat);
}
Also used : ElementNameStrategy(org.apache.camel.dataformat.soap.name.ElementNameStrategy) GetCustomersByName(com.example.customerservice.GetCustomersByName) TypeNameStrategy(org.apache.camel.dataformat.soap.name.TypeNameStrategy)

Example 7 with ElementNameStrategy

use of org.apache.camel.dataformat.soap.name.ElementNameStrategy in project camel by apache.

the class SoapRoundtripTest method createRouteBuilder.

@Override
protected RouteBuilder createRouteBuilder() throws Exception {
    return new RouteBuilder() {

        String jaxbPackage = GetCustomersByName.class.getPackage().getName();

        @Override
        public void configure() throws Exception {
            ElementNameStrategy elNameStrat = new TypeNameStrategy();
            from("direct:start").marshal().soapjaxb(jaxbPackage, elNameStrat).unmarshal().soapjaxb(jaxbPackage, elNameStrat).to("mock:result");
        }
    };
}
Also used : ElementNameStrategy(org.apache.camel.dataformat.soap.name.ElementNameStrategy) RouteBuilder(org.apache.camel.builder.RouteBuilder) TypeNameStrategy(org.apache.camel.dataformat.soap.name.TypeNameStrategy)

Aggregations

ElementNameStrategy (org.apache.camel.dataformat.soap.name.ElementNameStrategy)7 GetCustomersByName (com.example.customerservice.GetCustomersByName)4 TypeNameStrategy (org.apache.camel.dataformat.soap.name.TypeNameStrategy)4 RouteBuilder (org.apache.camel.builder.RouteBuilder)3 ServiceInterfaceStrategy (org.apache.camel.dataformat.soap.name.ServiceInterfaceStrategy)3 InputStream (java.io.InputStream)1 SoapJaxbDataFormat (org.apache.camel.dataformat.soap.SoapJaxbDataFormat)1