Package javax.xml.soap

Examples of javax.xml.soap.Node


        Iterator childElementsCount = soapBody.getChildElements();
        Iterator childElements = soapBody.getChildElements();

        int childCount = 0;
        while (childElementsCount.hasNext()) {
            Node node = (Node)childElementsCount.next();
            childCount++;
        }
        assertEquals(childCount, 1);
        SOAPElement se2 = (SOAPElement)childElements.next();
        if (!se.equals(se2)) {
View Full Code Here


        Iterator childElementsCount = soapBody.getChildElements();
        Iterator childElements = soapBody.getChildElements();

        int childCount = 0;
        while (childElementsCount.hasNext()) {
            Node node = (Node)childElementsCount.next();
            childCount++;
        }
        assertEquals(childCount, 1);
        SOAPElement se2 = (SOAPElement)childElements.next();
        assertEquals(se, se2);
View Full Code Here

        SOAPElement child = soapBody.addChildElement(qname1);
        child.addTextNode("foo");
       
        assertTrue(child.getChildElements().hasNext());
       
        Node textNode = (Node)child.getChildElements().next();
        assertTrue(textNode instanceof Text);
       
        /*
        child.removeChild(textNode);
       
View Full Code Here

                                                   attrNode.getNodeValue());               
        }

        NodeList childNodes = node.getChildNodes();
        for (int i = 0; i < childNodes.getLength(); i++) {
            Node childSAAJNode = toSAAJNode(childNodes.item(i), saajEle);
            if (childSAAJNode instanceof javax.xml.soap.Text) {
                saajEle.addTextNode(childSAAJNode.getValue());
            } else {
                saajEle.addChildElement((javax.xml.soap.SOAPElement)childSAAJNode);
            }
        }
        return saajEle;
View Full Code Here

    private Iterator getChildren(Iterator childIter) {
        Collection childElements = new ArrayList();
        while (childIter.hasNext()) {
            org.w3c.dom.Node domNode = (org.w3c.dom.Node)childIter.next();
            Node saajNode = toSAAJNode(domNode);
            if (saajNode instanceof javax.xml.soap.Text) {
                childElements.add(saajNode);
            } else if (!(saajNode instanceof SOAPBodyElement)) {
                // silently replace node, as per saaj 1.2 spec
                if (domNode instanceof ElementImpl) {
View Full Code Here

     */
    static javax.xml.soap.Node toSAAJNode(org.w3c.dom.Node domNode, Node parentNode) {
        if (domNode == null) {
            return null;
        }
        Node saajNode = (Node)((NodeImpl)domNode).getUserData(SAAJ_NODE);
        if (saajNode == null) {  // if SAAJ node has not been set in userData, try to construct it
            return toSAAJNode2(domNode, parentNode);
        }
        // update siblings for text nodes
        if (domNode instanceof org.w3c.dom.Text || domNode instanceof org.w3c.dom.Comment) {
View Full Code Here

      List     text_children = new ArrayList(  );
      Iterator node_iter     = soap_elem.getChildElements(  );

      while ( node_iter.hasNext(  ) )
      {
         Node child_node = (Node) node_iter.next(  );

         if ( isSOAPElement( child_node ) )
         {
            elem_children.add( child_node );
         }
View Full Code Here

                                int          depth )
   throws SOAPException
   {
      while ( children.hasNext(  ) )
      {
         Node child = (Node) children.next(  );

         buildSOAPNodeStringBuffer( buf, root_soap_elem, child, depth );
      }
   }
View Full Code Here

      //String state = resState.getResourceState().getState();
      String state = null;

      while ( childElements.hasNext(  ) )
      {
         Node o = (Node) childElements.next(  );

         if ( o instanceof SOAPElement )
         {
            SOAPElement elem           = (SOAPElement) o;
            Iterator    childElements2 = elem.getChildElements(  );

            while ( childElements2.hasNext(  ) )
            {
               Node child = (Node) childElements2.next(  );

               if ( child instanceof SOAPElement )
               {
                  SOAPElement stateElem = (SOAPElement) child;
View Full Code Here

      List     text_children = new ArrayList(  );
      Iterator node_iter     = soap_elem.getChildElements(  );

      while ( node_iter.hasNext(  ) )
      {
         Node child_node = (Node) node_iter.next(  );

         if ( isSOAPElement( child_node ) )
         {
            elem_children.add( child_node );
         }
View Full Code Here

TOP

Related Classes of javax.xml.soap.Node

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.