* Writes the payload as SAX events.
*/
protected void writePayloadTo(ContentHandler contentHandler, ErrorHandler errorHandler, boolean fragment) throws SAXException {
try {
if(fragment)
contentHandler = new FragmentContentHandler(contentHandler);
AttachmentMarshallerImpl am = new AttachmentMarshallerImpl(attachmentSet);
bridge.marshal(jaxbObject,contentHandler, am);
am.cleanup();
} catch (JAXBException e) {
// this is really more helpful but spec compliance