background image

5. SOAP with Attachments API for Java

<< More information about StAX | Overview of SAAJ >>
<< More information about StAX | Overview of SAAJ >>
117
5
SOAP with
Attachments API for
Java
S
OAP
with Attachments API for Java (SAAJ) is used mainly for the SOAP
messaging that goes on behind the scenes in JAX-WS handlers and JAXR imple-
mentations. Secondarily, it is an API that developers can use when they choose
to write SOAP messaging applications directly rather than use JAX-WS. The
SAAJ API allows you to do XML messaging from the Java platform: By simply
making method calls using the SAAJ API, you can read and write SOAP-based
XML messages, and you can optionally send and receive such messages over the
Internet (some implementations may not support sending and receiving). This
chapter will help you learn how to use the SAAJ API.
The SAAJ API conforms to the Simple Object Access Protocol (SOAP) 1.1 and
1.2 specifications and the SOAP with Attachments specification. The SAAJ 1.3
specification defines the
javax.xml.soap
package, which contains the API for
creating and populating a SOAP message. This package has all the API neces-
sary for sending request-response messages. (Request-response messages are
explained in SOAPConnection Objects, page 122.)