org.apache.axis2.saaj.util
Class SAAJUtil

java.lang.Object
  extended by org.apache.axis2.saaj.util.SAAJUtil

public class SAAJUtil
extends java.lang.Object

Utility class for the Axis2-WSS4J Module


Constructor Summary
SAAJUtil()
           
 
Method Summary
static boolean compareContentTypes(java.lang.String contentType1, java.lang.String contentType2)
           
static javax.xml.soap.MimeHeaders copyMimeHeaders(javax.xml.soap.MimeHeaders headers)
          Create a copy of an existing MimeHeaders object.
static org.w3c.dom.Document getDocumentFromSOAPEnvelope(org.apache.axiom.soap.SOAPEnvelope env)
          Create a DOM Document using the org.apache.axiom.soap.SOAPEnvelope
static org.apache.axiom.soap.SOAPEnvelope getSOAPEnvelopeFromDOOMDocument(org.w3c.dom.Document doc)
           
static java.lang.String normalizeContentType(java.lang.String contentType)
          Normalize a content type specification.
static org.w3c.dom.Element toDOM(org.apache.axiom.om.OMElement element)
          Convert a given OMElement to a DOM Element
static org.apache.axiom.soap.impl.dom.SOAPEnvelopeImpl toDOOMSOAPEnvelope(org.apache.axiom.soap.SOAPEnvelope env)
          Create a DOM Document using the org.apache.axiom.soap.SOAPEnvelope
static org.apache.axiom.soap.SOAPEnvelope toOMSOAPEnvelope(org.w3c.dom.Element elem)
           
static org.apache.axiom.soap.SOAPEnvelope toOMSOAPEnvelope(javax.xml.soap.SOAPMessage message)
          Convert a SAAJ message to an Axiom SOAP envelope object and process xop:Include elements.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SAAJUtil

public SAAJUtil()
Method Detail

getDocumentFromSOAPEnvelope

public static org.w3c.dom.Document getDocumentFromSOAPEnvelope(org.apache.axiom.soap.SOAPEnvelope env)
Create a DOM Document using the org.apache.axiom.soap.SOAPEnvelope

Parameters:
env - An org.apache.axiom.soap.SOAPEnvelope instance
Returns:
the DOM Document of the given SOAP Envelope

toDOOMSOAPEnvelope

public static org.apache.axiom.soap.impl.dom.SOAPEnvelopeImpl toDOOMSOAPEnvelope(org.apache.axiom.soap.SOAPEnvelope env)
Create a DOM Document using the org.apache.axiom.soap.SOAPEnvelope

Parameters:
env - An org.apache.axiom.soap.SOAPEnvelope instance
Returns:
the org.apache.axis2.soap.impl.dom.SOAPEnvelopeImpl of the given SOAP Envelope

getSOAPEnvelopeFromDOOMDocument

public static org.apache.axiom.soap.SOAPEnvelope getSOAPEnvelopeFromDOOMDocument(org.w3c.dom.Document doc)

toOMSOAPEnvelope

public static org.apache.axiom.soap.SOAPEnvelope toOMSOAPEnvelope(org.w3c.dom.Element elem)

toOMSOAPEnvelope

public static org.apache.axiom.soap.SOAPEnvelope toOMSOAPEnvelope(javax.xml.soap.SOAPMessage message)
                                                           throws javax.xml.soap.SOAPException
Convert a SAAJ message to an Axiom SOAP envelope object and process xop:Include elements.

Parameters:
message - the SAAJ message
Returns:
the OM SOAP envelope
Throws:
javax.xml.soap.SOAPException

toDOM

public static org.w3c.dom.Element toDOM(org.apache.axiom.om.OMElement element)
                                 throws java.lang.Exception
Convert a given OMElement to a DOM Element

Parameters:
element -
Returns:
DOM Element
Throws:
java.lang.Exception

copyMimeHeaders

public static javax.xml.soap.MimeHeaders copyMimeHeaders(javax.xml.soap.MimeHeaders headers)
Create a copy of an existing MimeHeaders object.

Parameters:
headers - the object to copy
Returns:
a copy of the MimeHeaders object

normalizeContentType

public static java.lang.String normalizeContentType(java.lang.String contentType)
Normalize a content type specification. This removes all parameters from the content type and converts it to lower case.

Parameters:
contentType - the content type to normalize
Returns:
the normalized content type

compareContentTypes

public static boolean compareContentTypes(java.lang.String contentType1,
                                          java.lang.String contentType2)


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.