Package org.springframework.ws.soap.addressing.client

Examples of org.springframework.ws.soap.addressing.client.ActionCallback


        Assertions.assertThat(channelOut().getAction()).isEqualTo(new URI("http://faultHeader.com"));
    }

    @Test
    public void onlyCustomOutputSpecified4output() throws Exception {
        ActionCallback requestCallback = channelIn("http://uriOutputOnly-ok.com/");

        webServiceTemplate.sendSourceAndReceiveToResult(source, requestCallback, result);

        Assertions.assertThat(channelOut().getAction()).isEqualTo(new URI("http://customURIOutputAction"));
    }
View Full Code Here


        Assertions.assertThat(channelOut().getAction()).isEqualTo(new URI("http://customURIOutputAction"));
    }

    @Test
    public void onlyCustomOutputSpecified4fault() throws Exception {
        ActionCallback requestCallback = channelIn("http://uriOutputOnly-fault.com/");
        try {
            webServiceTemplate.sendSourceAndReceiveToResult(source, requestCallback, result);
        } catch (SoapFaultClientException e) {
            // ok - cause fault response
        }
View Full Code Here

        Assertions.assertThat(channelOut().getAction()).isEqualTo(getDefaultResponseAction());
    }

    @Test
    public void onlyCustomFaultSpecified4output() throws Exception {
        ActionCallback requestCallback = channelIn("http://uriFaultOnly-ok.com/");

        webServiceTemplate.sendSourceAndReceiveToResult(source, requestCallback, result);

        Assertions.assertThat(channelOut().getAction()).isEqualTo(getDefaultResponseAction());
    }
View Full Code Here

        Assertions.assertThat(channelOut().getAction()).isEqualTo(getDefaultResponseAction());
    }

    @Test
    public void onlyCustomFaultSpecified4fault() throws Exception {
        ActionCallback requestCallback = channelIn("http://uriFaultOnly-fault.com/");
        try {
            webServiceTemplate.sendSourceAndReceiveToResult(source, requestCallback, result);
        } catch (SoapFaultClientException e) {
            // ok - cause fault response
        }
View Full Code Here

                SoapHeader header = ((SoapMessage) message).getSoapHeader();
                XML_CONVERTER.toResult(soapHeaderSource, header.getResult());
            }

            if (wsAddressingAction != null) {
                ActionCallback actionCallback = new ActionCallback(wsAddressingAction);
                if (wsReplyTo != null) {
                    actionCallback.setReplyTo(new EndpointReference(wsReplyTo));
                }

                if (wsFaultTo != null) {
                    actionCallback.setFaultTo(new EndpointReference(wsFaultTo));
                }
                actionCallback.doWithMessage(message);
            }

            configuration.getMessageFilter().filterProducer(exchange, message);
        }
View Full Code Here

     * @return
     * @throws URISyntaxException
     */
    protected final ActionCallback actionAndReplyTo(String action, String replyTo) throws URISyntaxException {
        requestInputAction = action;
        ActionCallback requestCallback = new ActionCallback(action);
        if (replyTo != null) {
            requestCallback.setReplyTo(new EndpointReference(new URI(replyTo)));
        }
        return requestCallback;
    }
View Full Code Here

     * @return
     * @throws URISyntaxException
     */
    protected final ActionCallback toAndReplyTo(String to, String replyTo) throws URISyntaxException {
        requestInputAction = "http://doesn-not-matter.com";
        ActionCallback requestCallback = new ActionCallback(new URI(requestInputAction), new Addressing10(), new URI(to));
        if (replyTo != null) {
            requestCallback.setReplyTo(new EndpointReference(new URI(replyTo)));
        }
        return requestCallback;
    }
View Full Code Here

            // Add WS-Addressing Action to webservice request (the WS-Addressing
            // 'to' header will default to the URL of the connection).
            // Note that exchange header takes precedence over endpoint option
            URI wsAddressingAction = wsAddressingActionHeader != null ? wsAddressingActionHeader : endpoint.getConfiguration().getWsAddressingAction();
            if (wsAddressingAction != null) {
                new ActionCallback(wsAddressingAction).doWithMessage(message);
            }
        }
View Full Code Here

            URI wsAddressingAction = wsAddressingActionHeader != null ? wsAddressingActionHeader : configuration.getWsAddressingAction();
            URI wsReplyTo = wsReplyToHeader != null ? wsReplyToHeader : configuration.getReplyTo();
            URI wsFaultTo = wsFaultToHeader != null ? wsFaultToHeader : configuration.getFaultTo();
           
            if (wsAddressingAction != null) {
                ActionCallback actionCallback = new ActionCallback(wsAddressingAction);
                if (wsReplyTo != null) {
                    actionCallback.setReplyTo(new EndpointReference(wsReplyTo));
                }

                if (wsFaultTo != null) {
                    actionCallback.setFaultTo(new EndpointReference(wsFaultTo));
                }
                actionCallback.doWithMessage(message);
            }
           
            configuration.getMessageFilter().filterProducer(exchange, message);
        }
View Full Code Here

TOP

Related Classes of org.springframework.ws.soap.addressing.client.ActionCallback

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.