Package javax.xml.soap

Examples of javax.xml.soap.SOAPElement


   public static void serialize( Writer writer,
                                 Object obj,
                                 QName  name )
   throws SerializationException
   {
      SOAPElement soapElement = ObjectSerializer.toSOAPElement( obj, name );
      try
      {
         AnyHelper.write( writer, (MessageElement) soapElement );
      }
      catch ( Exception e )
View Full Code Here


        if ( domElem == null )
        {
            return null;
        }

        SOAPElement soapElem;
        if ( domElem instanceof SOAPElement )
        {
            soapElem = (SOAPElement) domElem;
        }
        else
View Full Code Here

            org.w3c.dom.Node node = children.item( i );
            short node_type = node.getNodeType();

            if ( node_type == org.w3c.dom.Node.ELEMENT_NODE )
            {
                SOAPElement new_elem =
                        soap_elem.addChildElement( node.getLocalName(),
                                getPrefix( node ),
                                getNamespaceURI( node ) );

                buildSOAPElement( (Element) node, new_elem );
View Full Code Here

                                                   int          depth )
   throws SOAPException
   {
      if ( isElement( current_soap_node ) )
      {
         SOAPElement soap_elem   = (SOAPElement) current_soap_node;
         Name        elem_pqname = null;

         try
         {
            elem_pqname = soap_elem.getElementName(  );
         }
         catch ( RuntimeException re )
         {
            //LOG.error( ResourceKeys.MSG.getMsg( ResourceKeys.METHOD_FAILED, "SOAPElement.getElementName()" ) );
         }
View Full Code Here

         if ( !( obj_child instanceof SOAPElement ) )
         {
            continue;
         }

         SOAPElement child = (SOAPElement) obj_child;

         prefix = getPrefix( child,
                             pqname.getURI(  ) );

         if ( ( prefix != null ) && !prefix.equals( "" ) )
View Full Code Here

                operationName = null;
                parameterNames = null;
            } else {
                SOAPBody body = getBody(message);

                SOAPElement operation = ((SOAPElement) body.getChildElements().next());
                this.operationName = operation.getElementName().toString();

                this.parameterNames = new ArrayList();
                for (Iterator i = operation.getChildElements(); i.hasNext();) {
                    SOAPElement parameter = (SOAPElement) i.next();
                    String element = parameter.getElementName().toString();
                    parameterNames.add(element);
                }
            }
        }
View Full Code Here

            }

            SOAPBody body = getBody(message);

            // Handlers can't change the operation
            SOAPElement operation = ((SOAPElement) body.getChildElements().next());
            if (!this.operationName.equals(operation.getElementName().toString())) {
                return false;
            }

            Iterator parameters = operation.getChildElements();
            for (Iterator i = parameterNames.iterator(); i.hasNext();) {
                // Handlers can't remove parameters
                if (!parameters.hasNext()) {
                    return false;
                }

                String original = (String) i.next();
                SOAPElement parameter = (SOAPElement) parameters.next();
                // Handlers can't change parameter types
                if (parameter == null || !original.equals(parameter.getElementName().toString())) {
                    return false;
                }
            }

            // Handlers can't add parameters
View Full Code Here

            if (head != null) {
                Iterator<Node> it = CastUtils.cast(head.getChildElements());
                while (it != null && it.hasNext()) {
                    Node nd = it.next();
                    if (nd instanceof SOAPElement) {
                        SOAPElement el = (SOAPElement)nd;
                        if (el.hasAttributeNS(Names.WSA_NAMESPACE_NAME, "IsReferenceParameter")
                            && ("1".equals(el.getAttributeNS(Names.WSA_NAMESPACE_NAME,
                                                             "IsReferenceParameter"))
                                || Boolean.parseBoolean(el.getAttributeNS(Names.WSA_NAMESPACE_NAME,
                                                                          "IsReferenceParameter")))) {
                            params.add(el);
                        }
                    }
                }
View Full Code Here

        // We're always going to include a DispositionReport (for
        // the hell of it) so that's what we're doing here.
      
        Detail faultDetail = soapFault.addDetail();
       
        SOAPElement dispRpt = faultDetail.addChildElement("dispositionReport","",IRegistry.UDDI_V2_NAMESPACE);       
        dispRpt.setAttribute("generic",IRegistry.UDDI_V2_GENERIC);
        dispRpt.setAttribute("operator",Config.getOperator());
       
        SOAPElement result = dispRpt.addChildElement("result");
        result.setAttribute("errno",errno);
       
        SOAPElement errInfo = result.addChildElement("errInfo");
        errInfo.setAttribute("errCode",errCode);
        errInfo.setValue(errText);
      }
      catch (Exception e) { // if we end up in here it's just NOT good.
        log.error("A serious error has occured while assembling the SOAP Fault.",e);
      }
    }
View Full Code Here

    public static String getJMSChildElementValue(SOAPElement soapElement, String localName) throws SOAPException {

        String value = null;

        SOAPElement se = getJMSChildElement(soapElement, localName);

        if (se != null) {
            value = se.getValue();
        }

        return value;
    }
View Full Code Here

TOP

Related Classes of javax.xml.soap.SOAPElement

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.