Package org.apache.ws.commons.soap

Examples of org.apache.ws.commons.soap.SOAPBody


                // send the request and wait for reponse
                MessageContext response = send(msgctx, clientOptions.getTransportIn());

                // call the callback
                SOAPEnvelope resenvelope = response.getEnvelope();
                SOAPBody body = resenvelope.getBody();

                if (body.hasFault()) {
                    Exception ex = body.getFault().getException();

                    if (ex != null) {
                        callback.onError(ex);
                    } else {

                        // todo this needs to be fixed
                        callback.onError(new Exception(body.getFault().getReason().getText()));
                    }
                } else {
                    AsyncResult asyncResult = new AsyncResult(response);

                    callback.onComplete(asyncResult);
View Full Code Here


     * @param env
     * @param type
     * @return the relevant element to be databound
     */
    protected OMElement getElement(SOAPEnvelope env, String type) {
        SOAPBody body = env.getBody();
        OMElement element = body.getFirstElement();

        if (WSDLService.STYLE_RPC.equals(type)) {
            return element.getFirstElement();    // todo this needs to be fixed
        } else if (WSDLService.STYLE_DOC.equals(type)) {
            return element;
View Full Code Here

            try {
                // send the request and wait for reponse
                MessageContext response = send(msgctx);
                // call the callback
                SOAPEnvelope resenvelope = response.getEnvelope();
                SOAPBody body = resenvelope.getBody();
                if (body.hasFault()) {
                    Exception ex = body.getFault().getException();

                    if (ex != null) {
                        callback.onError(ex);
                    } else {
                        callback.onError(new Exception(body.getFault()
                                .getReason().getText()));
                    }
                } else {
                    AsyncResult asyncResult = new AsyncResult(response);
View Full Code Here

        this.results = results;
        this.button = button;
    }

    public void onComplete(AsyncResult result) {
        SOAPBody body = result.getResponseEnvelope().getBody();
        this.getQueueDeleteStatus(body);
        this.button.setText("Delete Queue");
    }
View Full Code Here

        this.enqueue = enqueue;
        this.result = result;
    }

    public void onComplete(AsyncResult result) {
        SOAPBody body = result.getResponseEnvelope().getBody();
        getResults(body);
    }
View Full Code Here

        this.result = result;
        this.button = button;
    }

    public void onComplete(AsyncResult result) {
        SOAPBody body = result.getResponseEnvelope().getBody();
        getResults(body);
        this.button.setText("Load Queue");
    }
View Full Code Here

        this.enqueue = enqueue;
        this.result = result;
    }

    public void onComplete(AsyncResult result) {
        SOAPBody body = result.getResponseEnvelope().getBody();
        getResults(body);
    }
View Full Code Here

        this.queueCode = queueCode;
        this.results = results;
    }

    public void onComplete(AsyncResult result) {
        SOAPBody body = result.getResponseEnvelope().getBody();
        this.getQueueEntryBody(body);
    }
View Full Code Here

     * @param result
     */
    private void extractDetails(AsyncResult result) {
        Iterator iterator, iterator2;
        OMNode node;
        SOAPBody body;
        OMElement operation, elem;
        SOAPEnvelope resEnvelope;
        resEnvelope = result.getResponseEnvelope();
        body = resEnvelope.getBody();
        operation = body.getFirstElement();
        if (body.hasFault()) {
            snippet =
                    snippet +
                    "A Fault message received, Check your Licence key. Else you have reached the" +
                    " daily limit of 1000 requests";
        } else {
View Full Code Here

    public String getResponse(SOAPEnvelope responseEnvelope) {
        QName qName1 = new QName("urn:GoogleSearch",
                "doSpellingSuggestionResponse");

        SOAPBody body = responseEnvelope.getBody();
        if (body.hasFault()) {
            observer.updateError(body.getFault().getException().getMessage());
            return null;
        } else {
            OMElement root = body.getFirstChildWithName(qName1);
            OMElement val;
            if (root != null) {
                // val = root.getFirstChildWithName(qName2);
                val = root.getFirstElement();
            } else {
View Full Code Here

TOP

Related Classes of org.apache.ws.commons.soap.SOAPBody

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.