Sun Java Solaris Communities My SDN Account Join SDN

SAAJ

SAAJ FAQ

 
API Specifications
BluePrints
Documentation
FAQs
 
Bug Database
Forums
 
 
SOAP with Attachments API for Java (SAAJ)
Frequently Asked Questions

Q. What is the SOAP with Attachments API for Java (SAAJ) ?

A: SAAJ is an API that allows users to create and send SOAP messages by means of the javax.xml.soap package. It is used for the SOAP messaging that goes on behind the scenes in JAX-RPC and JAXR implementations. Developers can also use it to write SOAP messaging applications directly instead of using JAX-RPC.

Q: What standards is SAAJ based on?

A: SAAJ is based on the Simple Object Access Protocol (SOAP) 1.1 and SOAP with Attachments specifications.

Q. Do I have to use the J2EE platform to use SAAJ?

A: No, you are free to use the Java 2 Platform, Standard Edition (J2SE) as well as the Java 2 Platform, Enterprise Edition (J2EE). A client can use the J2SE platform to send request-response messages to Web services that process request-response messages. This requires no deployment or configuration from the client, so it is easy to do.

Q. Can a SAAJ message be routed to more than one destination?

A: Yes. Intermediate recipients can be specified in a message's header. One way this capability can be used is to automate business processes. For example, two businesses can agree to the conditions under which they exchange XML documents so that they can implement the automatic generation of messages and responses. Assume that two businesses have an arrangement specifying that purchase orders will go first to the order entry department, then to the order confirmation department, then to the shipping department, and finally to the billing department. Each department is an intermediate recipient (called an actor). After an actor has done its part, it removes everything in the header that relates to it and sends the message on to the next actor listed in the header.

Q. What are the SAAJ packaging models?

A: There are two different packaging models for SOAP messages, one that includes attachments and one that does not. If the SOAP message includes AttachmentPart objects, then the message is encoded as a MIME message.

Q. What new features does SAAJ v1.2 add?

A: SAAJ 1.2 provides the following new features:

  • Support for the WS-I Basic Profile 1.0
  • DOM integration: SAAJ APIs now extend Document Object Model (DOM) APIs
  • SOAPMessage properties for setting character set encoding and turning on the writing of an XML declaration at the start of the SOAP part of the message
  • Several new methods for ease of use

Related Links