Package javax.xml.soap

Examples of javax.xml.soap.MimeHeaders.addHeader()


                // Set SOAPAction
                if (soapAction != null) {
                  // Setting soap action using both approaches, as CXF needs one and JBossWS-Native the other
                  proxy.getRequestContext().put(Dispatch.SOAPACTION_URI_PROPERTY, soapAction);
                  MimeHeaders hd = soapRequestMessage.getMimeHeaders();
                  hd.addHeader("SOAPAction", soapAction);
                } else if (log.isDebugEnabled()) {
                  log.debug("SOAPAction not set");
                }

                // Set client side timeout for the invocation
View Full Code Here


                  // Set SOAPAction
                  if (soapAction != null) {
                    // Setting soap action using both approaches, as CXF needs one and JBossWS-Native the other
                    proxy.getRequestContext().put(Dispatch.SOAPACTION_URI_PROPERTY, soapAction);
                    MimeHeaders hd = soapRequestMessage.getMimeHeaders();
                    hd.addHeader("SOAPAction", soapAction);
                  } else if (log.isDebugEnabled()) {
                    log.debug("SOAPAction not set");
                  }
                 
                  proxy.invokeOneWay(soapRequestMessage);
View Full Code Here

            if (httpHeaders != null) {
                for (String key : httpHeaders.keySet()) {
                    if (null != key) {
                        List<String> values = httpHeaders.get(key);
                        for (String value : values) {
                            headers.addHeader(key, value);
                        }
                    }
                }
            }
View Full Code Here

                    if (synCtx.isSOAP11()) {
                        smsg = mf.createMessage(new MimeHeaders(),
                                new ByteArrayInputStream(cachedObj.getResponseEnvelope()));
                    } else {
                        MimeHeaders mimeHeaders = new MimeHeaders();
                        mimeHeaders.addHeader("Content-ID", IDGenerator.generateID());
                        mimeHeaders.addHeader("content-type",
                                HTTPConstants.MEDIA_TYPE_APPLICATION_SOAP_XML);
                        smsg = mf.createMessage(mimeHeaders,
                                new ByteArrayInputStream((cachedObj).getResponseEnvelope()));
                    }
View Full Code Here

                        smsg = mf.createMessage(new MimeHeaders(),
                                new ByteArrayInputStream(cachedObj.getResponseEnvelope()));
                    } else {
                        MimeHeaders mimeHeaders = new MimeHeaders();
                        mimeHeaders.addHeader("Content-ID", IDGenerator.generateID());
                        mimeHeaders.addHeader("content-type",
                                HTTPConstants.MEDIA_TYPE_APPLICATION_SOAP_XML);
                        smsg = mf.createMessage(mimeHeaders,
                                new ByteArrayInputStream((cachedObj).getResponseEnvelope()));
                    }
View Full Code Here

        while (enumeration.hasMoreElements()) {
            String headerName = (String) enumeration.nextElement();
            String headerValue = httpServletRequest.getHeader(headerName);
            StringTokenizer values = new StringTokenizer(headerValue, ",");
            while (values.hasMoreTokens()) {
                headers.addHeader(headerName, values.nextToken().trim());
            }
        }
        return headers;
    }
View Full Code Here

                  .isEmpty(
                      headers.getHeader(TransportConstants.HEADER_CONTENT_TYPE))) {
                  SOAPEnvelope envelope1 = message.getSOAPPart().getEnvelope();
                  if (envelope1.getElementQName().getNamespaceURI()
                          .equals(SoapVersion.SOAP_11.getEnvelopeNamespaceUri())) {
                      headers.addHeader(TransportConstants.HEADER_CONTENT_TYPE, SoapVersion.SOAP_11.getContentType());
                  }
                  else {
                      headers.addHeader(TransportConstants.HEADER_CONTENT_TYPE, SoapVersion.SOAP_12.getContentType());
                  }
                    message.saveChanges();
View Full Code Here

                  if (envelope1.getElementQName().getNamespaceURI()
                          .equals(SoapVersion.SOAP_11.getEnvelopeNamespaceUri())) {
                      headers.addHeader(TransportConstants.HEADER_CONTENT_TYPE, SoapVersion.SOAP_11.getContentType());
                  }
                  else {
                      headers.addHeader(TransportConstants.HEADER_CONTENT_TYPE, SoapVersion.SOAP_12.getContentType());
                  }
                    message.saveChanges();
              }
              for (Iterator<?> iterator = headers.getAllHeaders(); iterator.hasNext();) {
                  MimeHeader mimeHeader = (MimeHeader) iterator.next();
View Full Code Here

            while (enumeration.hasMoreElements()) {
                String headerName = (String) enumeration.nextElement();
                String headerValue = httpServletRequest.getHeader(headerName);
                StringTokenizer values = new StringTokenizer(headerValue, ",");
                while (values.hasMoreTokens()) {
                    headers.addHeader(headerName, values.nextToken().trim());
                }
            }
            return headers;
        }
View Full Code Here

            while (enumeration.hasMoreElements()) {
                String headerName = (String) enumeration.nextElement();
                String headerValue = httpServletRequest.getHeader(headerName);
                StringTokenizer values = new StringTokenizer(headerValue, ",");
                while (values.hasMoreTokens()) {
                    headers.addHeader(headerName, values.nextToken().trim());
                }
            }
            return headers;
        }
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.