Examples of XMLStringBlockFactory


Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        OMNamespace ns = soapEnv.getNamespace();
        assertTrue(ns.getNamespaceURI().equals(SOAP12_NS_URI));
       
        // Assuming no handlers are installed, the next thing that will happen
        // is the proxy code will ask for the business object (String).
        XMLStringBlockFactory blockFactory =
            (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);
        Block block = blockFactory.createFrom(m.getAsOMElement(), null, null);
        Object bo = block.getBusinessObject(true);
        assertTrue(bo instanceof String);
       
        // The block should be consumed
        assertTrue(block.isConsumed());
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

                            (protocol == Protocol.soap11) ? SOAPConstants.URI_NS_SOAP_1_1_ENVELOPE
                                    : SOAPConstants.URI_NS_SOAP_1_2_ENVELOPE;
                    QName soapEnvQname = new QName(soapNS, "Envelope");


                    XMLStringBlockFactory stringFactory =
                            (XMLStringBlockFactory)
                            FactoryRegistry.getFactory(XMLStringBlockFactory.class);
                    Block stringBlock = stringFactory.createFrom(stringValue, null, soapEnvQname);
                    Block block = blockFactory.createFrom(stringBlock, context);
                    value = block.getBusinessObject(true);
                }
            }
            return value;
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        // Create a SOAP 1.1 Message
        MessageFactory mf = (MessageFactory) FactoryRegistry.getFactory(MessageFactory.class);
        Message m = mf.create(Protocol.soap11);

        // Get the BlockFactory
        XMLStringBlockFactory f =
                (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);

        // Create a Block using the sample string as the content. This simulates
        // what occurs on the outbound JAX-WS dispatch<String> client
        Block block = f.createFrom(sampleText, null, null);

        // Add the block to the message as normal body content.
        m.setBodyBlock(block);

        // Check to see if the message is a fault. The client/server will always call this method.
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        // Create a SOAP 1.1 Message
        MessageFactory mf = (MessageFactory) FactoryRegistry.getFactory(MessageFactory.class);
        Message m = mf.create(Protocol.soap11);

        // Get the BlockFactory
        XMLStringBlockFactory f =
                (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);

        // Create a Block using the sample string as the content. This simulates
        // what occurs on the outbound JAX-WS dispatch<String> client
        Block block = f.createFrom(sampleText, null, null);

        // Add the block to the message as normal body content.
        m.setBodyBlock(block);

        // If there is a JAX-WS handler, the Message is converted into a SOAPEnvelope
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        MessageFactory mf = (MessageFactory)
            FactoryRegistry.getFactory(MessageFactory.class);
        Message m = mf.create(Protocol.soap11);
       
        // Get the BlockFactory
        XMLStringBlockFactory f = (XMLStringBlockFactory)
            FactoryRegistry.getFactory(XMLStringBlockFactory.class);
       
        // Sample text is whitespace.  There is no element
       
        String whiteSpaceText = "<!-- Comment -->";
        // Create a Block using the sample string as the content.  This simulates
        // what occurs on the outbound JAX-WS dispatch<String> client
        Block block = f.createFrom(whiteSpaceText, null, null);
       
        // Add the block to the message as normal body content.
        m.setBodyBlock(block);
       
        // If there is a JAX-WS handler, the Message is converted into a SOAPEnvelope
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        MessageFactory mf = (MessageFactory)
            FactoryRegistry.getFactory(MessageFactory.class);
        Message m = mf.create(Protocol.soap11);
       
        // Get the BlockFactory
        XMLStringBlockFactory f = (XMLStringBlockFactory)
            FactoryRegistry.getFactory(XMLStringBlockFactory.class);
       
        // Create a Block using the sample string as the content.  This simulates
        // what occurs on the outbound JAX-WS dispatch<String> client
        // In this case the sample string contains 2 elements a and aa
        Block block = f.createFrom(this.sampleDouble, null, null);
       
        // Add the block to the message as normal body content.
        m.setBodyBlock(block);
       
        // If there is a JAX-WS handler, the Message is converted into a SOAPEnvelope
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        assertTrue("XMLPart Representation is " + m.getXMLPartContentType(),
                   "OM".equals(m.getXMLPartContentType()));

        // Assuming no handlers are installed, the next thing that will happen
        // is the proxy code will ask for the business object (String).
        XMLStringBlockFactory blockFactory =
                (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);
        Block block = m.getBodyBlock(null, blockFactory);
        Object bo = block.getBusinessObject(true);
        assertTrue(bo instanceof String);
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        String name = soapEnvelope.getBody().getFirstChild().getLocalName();
        assertTrue("a".equals(name));

        // The next thing that will happen
        // is the proxy code will ask for the business object (String).
        XMLStringBlockFactory blockFactory =
                (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);
        Block block = m.getBodyBlock(null, blockFactory);
        Object bo = block.getBusinessObject(true);
        assertTrue(bo instanceof String);
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        String name = sm.getSOAPBody().getFirstChild().getLocalName();
        assertTrue("a".equals(name));

        // The next thing that will happen
        // is the proxy code will ask for the business object (String).
        XMLStringBlockFactory blockFactory =
                (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);
        Block block = m.getBodyBlock(null, blockFactory);
        Object bo = block.getBusinessObject(true);
        assertTrue(bo instanceof String);
View Full Code Here

Examples of org.apache.axis2.jaxws.message.factory.XMLStringBlockFactory

        assertTrue("XMLPart Representation is " + m.getXMLPartContentType(),
                    "OM".equals(m.getXMLPartContentType()));
       
        // The next thing that will happen
        // is the proxy code will ask for the business object (String).
        XMLStringBlockFactory blockFactory =
            (XMLStringBlockFactory) FactoryRegistry.getFactory(XMLStringBlockFactory.class);
        Block block = m.getBodyBlock(null, blockFactory);
        Object bo = block.getBusinessObject(true);
        assertTrue(bo instanceof String);
       
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.