Examples of DeserializationContext


Examples of org.apache.axis.encoding.DeserializationContext

    }

    public void testAddChild() throws Exception {
        SOAPConstants sc = SOAPConstants.SOAP11_CONSTANTS;
        EnvelopeBuilder eb = new EnvelopeBuilder(Message.REQUEST, sc);
        DeserializationContext dc = new DeserializationContextImpl(null,
                                                                   eb);
        MessageElement parent = new MessageElement("parent.names",
                                                "parent",
                                                "parns",
                                                null,
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

        assertTrue("Unexpected child", !c1only.hasNext());
    }
    public void testDetachNode() throws Exception {
        SOAPConstants sc = SOAPConstants.SOAP11_CONSTANTS;
        EnvelopeBuilder eb = new EnvelopeBuilder(Message.REQUEST, sc);
        DeserializationContext dc = new DeserializationContextImpl(null,
                                                                   eb);
        SOAPElement parent = new MessageElement("parent.names",
                                                "parent",
                                                "parns",
                                                null,
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

        if ( currentForm == FORM_INPUTSTREAM ) {
            is = new InputSource( (InputStream) currentMessage );
        } else {
            is = new InputSource(new StringReader(getAsString()));
        }
        DeserializationContext dser = new DeserializationContextImpl(is,
                                           getMessage().getMessageContext(),
                                           getMessage().getMessageType());

        // This may throw a SAXException
        try {
            dser.parse();
        } catch (SAXException e) {
            Exception real = e.getException();
            if (real == null)
                real = e;
            throw AxisFault.makeFault(real);
        }

        setCurrentMessage(dser.getEnvelope(), FORM_SOAPENVELOPE);

        log.debug("Exit: SOAPPart::getAsSOAPEnvelope");
        return (SOAPEnvelope)currentMessage;
    }
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

    }

    public void testAddChild() throws Exception {
        SOAPConstants sc = SOAPConstants.SOAP11_CONSTANTS;
        EnvelopeBuilder eb = new EnvelopeBuilder(Message.REQUEST, sc);
        DeserializationContext dc = new DeserializationContextImpl(null,
                                                                   eb);
        SOAPElement parent = new MessageElement("parent.names",
                                                "parent",
                                                "parns",
                                                null,
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

        assertTrue("Unexpected child", !c1only.hasNext());
    }
    public void testDetachNode() throws Exception {
        SOAPConstants sc = SOAPConstants.SOAP11_CONSTANTS;
        EnvelopeBuilder eb = new EnvelopeBuilder(Message.REQUEST, sc);
        DeserializationContext dc = new DeserializationContextImpl(null,
                                                                   eb);
        SOAPElement parent = new MessageElement("parent.names",
                                                "parent",
                                                "parns",
                                                null,
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

        log.debug(msgString);
        log.debug("---");

        StringReader reader = new StringReader(msgString);

        DeserializationContext dser = new DeserializationContextImpl(
            new InputSource(reader), msgContext, org.apache.axis.Message.REQUEST);
        dser.parse();

        SOAPEnvelope env = dser.getEnvelope();
        RPCElement rpcElem = (RPCElement)env.getFirstBody();
        RPCParam struct = rpcElem.getParam("struct");
        assertNotNull("No <struct> param", struct);

        Data val = (Data)struct.getValue();
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

    }

    public SOAPEnvelope(InputStream input) throws SAXException {
        InputSource is = new InputSource(input);
        header = new SOAPHeader(this, soapConstants); // soapConstants = null!
        DeserializationContext dser = null ;
        AxisClient     tmpEngine = new AxisClient(new NullProvider());
        MessageContext msgContext = new MessageContext(tmpEngine);
        dser = new DeserializationContextImpl(is, msgContext,
                                              Message.REQUEST, this );
        dser.parse();
    }
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

            } else if (event == STATE_END_PREFIX_MAPPING) {
                handler.endPrefixMapping((String)events.get(n, 1));
               
            } else if (event == STATE_NEWELEMENT) {
                if (handler instanceof DeserializationContext) {
                    DeserializationContext context =
                              (DeserializationContext)handler;
                    context.setCurElement(
                              (MessageElement)(events.get(n,1)));
                }
            }
        }
    }
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

             */
            ByteArrayOutputStream out = new ByteArrayOutputStream();
            resMsg.writeTo(out);
            ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());

            DeserializationContext dser =
                new DeserializationContext(new InputSource(in), resMsg.getMessageContext(), null);
            dser.parse();
            SOAPEnvelope responseEnvelope = dser.getEnvelope();

            SOAPBodyElement bodyEl = responseEnvelope.getFirstBody();
            if (bodyEl == null) {
                return null;
            }
View Full Code Here

Examples of org.apache.axis.encoding.DeserializationContext

                reader = new StringReader(msgString);
            } else {
                reader = new FileReader(args[0]);
            }

            DeserializationContext dser = new DeserializationContext(new InputSource(reader), msgContext, org.apache.axis.Message.REQUEST);
            dser.parse();
            SOAPEnvelope env = dser.getEnvelope();
            //System.out.println("********\n" + DOM2Writer.nodeToString(env, true) + "\n********");
           
            RPCElement rpcElem = (RPCElement) env.getFirstBody();
            RPCParam struct = rpcElem.getParam("struct");
            if (struct == null)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.