SOAPEnvelope (Axis API)
Keywords: org.apache.axis.message.SOAPEnvelope,SOAPEnvelope class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.axis.message
Class SOAPEnvelope

    java.lang.Object
      |
      +--org.apache.axis.message.MessageElement
            |
            +--org.apache.axis.message.SOAPEnvelope

All Implemented Interfaces:
  Node, java.io.Serializable, SOAPElement, SOAPEnvelope

public class SOAPEnvelope
extends MessageElement
implements SOAPEnvelope

Implementation of a SOAP Envelope

See Also:
  Serialized Form

Nested Class Summary

Nested classes inherited from class org.apache.axis.message.MessageElement
`MessageElement.QNameAttr`

Field Summary
`protected static org.apache.commons.logging.Log` | `log`
`java.lang.String` | `messageType`
`java.util.Vector` | `trailers`

Fields inherited from class org.apache.axis.message.MessageElement
`_isDirty, _isRoot, attributes, context, elementRep, encodingStyle, endEventIndex, href, id, message, name, namespaces, namespaceURI, parent, prefix, qNameAttrs, recorder, startContentsIndex, startEventIndex, textRep, typeQName`

Constructor Summary
`SOAPEnvelope()`
`SOAPEnvelope(boolean registerPrefixes, SOAPConstants soapConstants)`
`SOAPEnvelope(boolean registerPrefixes, SOAPConstants soapConstants, SchemaVersion schemaVersion)`
`SOAPEnvelope(java.io.InputStream input)`
`SOAPEnvelope(SOAPConstants soapConstants)`
`SOAPEnvelope(SOAPConstants soapConstants, SchemaVersion schemaVersion)`

Method Summary
`SOAPBody` | `addBody()` Add a soap body if one does not exist
`void` | `addBodyElement(SOAPBodyElement element)` Add a SOAP Body Element
`SOAPHeader` | `addHeader()` Add a soap header if one does not exist
`void` | `addHeader(SOAPHeaderElement hdr)` Add a HeaderElement
`void` | `addTrailer(MessageElement element)` Add an element to the trailer
`void` | `clearBody()` clear the elements in the soap body
`Name` | `createName(java.lang.String localName)` create a Name given the local part
`Name` | `createName(java.lang.String localName, java.lang.String prefix, java.lang.String uri)` Create a name given local part, prefix and uri
`SOAPBody` | `getBody()` Get the soap body
`SOAPBodyElement` | `getBodyByName(java.lang.String namespace, java.lang.String localPart)` Get a body element given its name
`java.util.Vector` | `getBodyElements()` Get all the BodyElement's in the soap body
`SOAPBodyElement` | `getFirstBody()` Get the first BodyElement in the SOAP Body
`SOAPHeader` | `getHeader()` Get the soap header
`SOAPHeaderElement` | `getHeaderByName(java.lang.String namespace, java.lang.String localPart)` Get a header by name (always respecting the currently in-scope actors list)
`SOAPHeaderElement` | `getHeaderByName(java.lang.String namespace, java.lang.String localPart, boolean accessAllHeaders)` Get a header by name, filtering for headers targeted at this engine depending on the accessAllHeaders parameter.
`java.util.Vector` | `getHeaders()` Get Headers
`java.util.Vector` | `getHeadersByActor(java.util.ArrayList actors)` Get all the headers targeted at a list of actors.
`java.util.Enumeration` | `getHeadersByName(java.lang.String namespace, java.lang.String localPart)` Get an enumeration of header elements given the namespace and localpart
`java.util.Enumeration` | `getHeadersByName(java.lang.String namespace, java.lang.String localPart, boolean accessAllHeaders)` Return an Enumeration of headers which match the given namespace and localPart.
`java.lang.String` | `getMessageType()` Get the Message Type (REQUEST/RESPONSE)
`SchemaVersion` | `getSchemaVersion()` Get the schema version for this envelope
`SOAPConstants` | `getSOAPConstants()` Get the soap constants for this envelope
`java.util.Vector` | `getTrailers()` Return trailers
`void` | `outputImpl(SerializationContext context)` Should make SOAPSerializationException?
`void` | `removeBody()` Remove the SOAP Body
`void` | `removeBodyElement(SOAPBodyElement element)` Remove a Body Element from the soap body
`void` | `removeHeader(SOAPHeaderElement hdr)` Remove a Header Element from SOAP Header
`void` | `removeHeaders()` Remove all headers
`void` | `removeTrailer(MessageElement element)` Remove an element from the trailer
`void` | `setBody(SOAPBody body)` Set the soap body
`void` | `setHeader(SOAPHeader hdr)` Set the SOAP Header
`void` | `setMessageType(java.lang.String messageType)` Set the Message Type (REQUEST/RESPONSE)
`void` | `setSAAJEncodingCompliance(boolean comply)`
`void` | `setSchemaVersion(SchemaVersion schemaVersion)` Set the schema version for this envelope
`void` | `setSoapConstants(SOAPConstants soapConstants)` Set the soap constants for this envelope

Methods inherited from class org.apache.axis.message.MessageElement
`addAttribute, addAttribute, addAttribute, addAttribute, addChild, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addMapping, addNamespaceDeclaration, addTextNode, detachNode, getAllAttributes, getAsDocument, getAsDOM, getAttributes, getAttributeValue, getAttributeValue, getChildElements, getChildElements, getChildren, getCompleteAttributes, getElementName, getEncodingStyle, getEnvelope, getFixupDeserializer, getHref, getID, getName, getNamespacePrefixes, getNamespaceURI, getNamespaceURI, getObjectValue, getParentElement, getPrefix, getPrefix, getQName, getRealElement, getRecorder, getType, getValue, getValueAsType, isDirty, isRoot, makeAttributesEditable, output, publishContents, publishToHandler, recycleNode, removeAttribute, removeChild, removeNamespaceDeclaration, setAttribute, setContentsIndex, setDirty, setEncodingStyle, setEndIndex, setEnvelope, setFixupDeserializer, setName, setNamespaceURI, setNSMappings, setObjectValue, setParentElement, setPrefix, setQName, setRecorder, setType, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Methods inherited from interface javax.xml.soap.SOAPElement
`addAttribute, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addNamespaceDeclaration, addTextNode, getAllAttributes, getAttributeValue, getChildElements, getChildElements, getElementName, getEncodingStyle, getNamespacePrefixes, getNamespaceURI, removeAttribute, removeNamespaceDeclaration, setEncodingStyle`

Methods inherited from interface javax.xml.soap.Node
`detachNode, getParentElement, getValue, recycleNode, setParentElement`

Field Detail

### log

    protected static org.apache.commons.logging.Log log

### trailers

    public java.util.Vector trailers

### messageType

    public java.lang.String messageType

Constructor Detail

### SOAPEnvelope

    public SOAPEnvelope()

### SOAPEnvelope

    public SOAPEnvelope(SOAPConstants soapConstants)

### SOAPEnvelope

    public SOAPEnvelope(SOAPConstants soapConstants,
                        SchemaVersion schemaVersion)

### SOAPEnvelope

    public SOAPEnvelope(boolean registerPrefixes,
                        SOAPConstants soapConstants)

### SOAPEnvelope

    public SOAPEnvelope(boolean registerPrefixes,
                        SOAPConstants soapConstants,
                        SchemaVersion schemaVersion)

### SOAPEnvelope

    public SOAPEnvelope(java.io.InputStream input)
                 throws org.xml.sax.SAXException

Method Detail

### getMessageType

    public java.lang.String getMessageType()

  Get the Message Type (REQUEST/RESPONSE)

  Returns:
    message type

### setMessageType

    public void setMessageType(java.lang.String messageType)

  Set the Message Type (REQUEST/RESPONSE)

  Parameters:
    `messageType` -

### getBodyElements

    public java.util.Vector getBodyElements()
                                     throws AxisFault

  Get all the BodyElement's in the soap body

  Returns:
    vector with body elements
  Throws:
    `AxisFault`

### getTrailers

    public java.util.Vector getTrailers()

  Return trailers

  Returns:

### getFirstBody

    public SOAPBodyElement getFirstBody()
                                 throws AxisFault

  Get the first BodyElement in the SOAP Body

  Returns:
    first Body Element
  Throws:
    `AxisFault`

### getHeaders

    public java.util.Vector getHeaders()
                                throws AxisFault

  Get Headers

  Returns:
    Vector containing Header's
  Throws:
    `AxisFault`

### getHeadersByActor

    public java.util.Vector getHeadersByActor(java.util.ArrayList actors)

  Get all the headers targeted at a list of actors.

### addHeader

    public void addHeader(SOAPHeaderElement hdr)

  Add a HeaderElement

  Parameters:
    `hdr` -

### addBodyElement

    public void addBodyElement(SOAPBodyElement element)

  Add a SOAP Body Element

  Parameters:
    `element` -

### removeHeaders

    public void removeHeaders()

  Remove all headers

### setHeader

    public void setHeader(SOAPHeader hdr)

  Set the SOAP Header

  Parameters:
    `hdr` -

### removeHeader

    public void removeHeader(SOAPHeaderElement hdr)

  Remove a Header Element from SOAP Header

  Parameters:
    `hdr` -

### removeBody

    public void removeBody()

  Remove the SOAP Body

### setBody

    public void setBody(SOAPBody body)

  Set the soap body

  Parameters:
    `body` -

### removeBodyElement

    public void removeBodyElement(SOAPBodyElement element)

  Remove a Body Element from the soap body

  Parameters:
    `element` -

### removeTrailer

    public void removeTrailer(MessageElement element)

  Remove an element from the trailer

  Parameters:
    `element` -

### clearBody

    public void clearBody()

  clear the elements in the soap body

### addTrailer

    public void addTrailer(MessageElement element)

  Add an element to the trailer

  Parameters:
    `element` -

### getHeaderByName

    public SOAPHeaderElement getHeaderByName(java.lang.String namespace,
                                             java.lang.String localPart)
                                      throws AxisFault

  Get a header by name (always respecting the currently in-scope actors list)

    `AxisFault`

### getHeaderByName

    public SOAPHeaderElement getHeaderByName(java.lang.String namespace,
                                             java.lang.String localPart,
                                             boolean accessAllHeaders)
                                      throws AxisFault

  Get a header by name, filtering for headers targeted at this engine depending on the accessAllHeaders parameter.

    `AxisFault`

### getBodyByName

    public SOAPBodyElement getBodyByName(java.lang.String namespace,
                                         java.lang.String localPart)
                                  throws AxisFault

  Get a body element given its name

  Parameters:
    `namespace` -
    `localPart` -
  Returns:
  Throws:
    `AxisFault`

### getHeadersByName

    public java.util.Enumeration getHeadersByName(java.lang.String namespace,
                                                  java.lang.String localPart)
                                           throws AxisFault

  Get an enumeration of header elements given the namespace and localpart

  Parameters:
    `namespace` -
    `localPart` -
  Returns:
  Throws:
    `AxisFault`

### getHeadersByName

    public java.util.Enumeration getHeadersByName(java.lang.String namespace,
                                                  java.lang.String localPart,
                                                  boolean accessAllHeaders)
                                           throws AxisFault

  Return an Enumeration of headers which match the given namespace and localPart. Depending on the value of the accessAllHeaders parameter, we will attempt to filter on the current engine's list of actors. !!! NOTE THAT RIGHT NOW WE ALWAYS ASSUME WE'RE THE "ULTIMATE DESTINATION" (i.e. we match on null actor). IF WE WANT TO FULLY SUPPORT INTERMEDIARIES WE'LL NEED TO FIX THIS.

    `AxisFault`

### outputImpl

    public void outputImpl(SerializationContext context)
                    throws java.lang.Exception

  Should make SOAPSerializationException?

  Overrides:
    `outputImpl` in class `MessageElement`
    `java.lang.Exception`

### getSOAPConstants

    public SOAPConstants getSOAPConstants()

  Get the soap constants for this envelope

  Returns:

### setSoapConstants

    public void setSoapConstants(SOAPConstants soapConstants)

  Set the soap constants for this envelope

  Parameters:
    `soapConstants` -

### getSchemaVersion

    public SchemaVersion getSchemaVersion()

  Get the schema version for this envelope

  Returns:

### setSchemaVersion

    public void setSchemaVersion(SchemaVersion schemaVersion)

  Set the schema version for this envelope

  Parameters:
    `schemaVersion` -

### addBody

    public SOAPBody addBody()
                     throws SOAPException

  Add a soap body if one does not exist

  Specified by:
    `addBody` in interface `SOAPEnvelope`
  Returns:
  Throws:
    `SOAPException`

### addHeader

    public SOAPHeader addHeader()
                         throws SOAPException

  Add a soap header if one does not exist

  Specified by:
    `addHeader` in interface `SOAPEnvelope`
  Returns:
  Throws:
    `SOAPException`

### createName

    public Name createName(java.lang.String localName)
                    throws SOAPException

  create a Name given the local part

  Specified by:
    `createName` in interface `SOAPEnvelope`
  Parameters:
    `localName` -
  Returns:
  Throws:
    `SOAPException`

### createName

    public Name createName(java.lang.String localName,
                           java.lang.String prefix,
                           java.lang.String uri)
                    throws SOAPException

  Create a name given local part, prefix and uri

  Specified by:
    `createName` in interface `SOAPEnvelope`
  Parameters:
    `localName` -
    `prefix` -
    `uri` -
  Returns:
  Throws:
    `SOAPException`

### getBody

    public SOAPBody getBody()
                     throws SOAPException

  Get the soap body

  Specified by:
    `getBody` in interface `SOAPEnvelope`
  Returns:
  Throws:
    `SOAPException`

### getHeader

    public SOAPHeader getHeader()
                         throws SOAPException

  Get the soap header

  Specified by:
    `getHeader` in interface `SOAPEnvelope`
  Returns:
  Throws:
    `SOAPException`

### setSAAJEncodingCompliance

    public void setSAAJEncodingCompliance(boolean comply)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003 Apache Web Services Project. All Rights Reserved.