public static String debugAxisObject(org.apache.axis2.databinding.ADBBean b){
try {
org.apache.axis2.databinding.utils.writer.MTOMAwareOMBuilder omwriter=
new org.apache.axis2.databinding.utils.writer.MTOMAwareOMBuilder();
b.serialize(
new javax.xml.namespace.QName("http://localhost/",
b.getClass().getSimpleName(), "ns1"),
org.apache.axiom.om.OMAbstractFactory.getOMFactory(),
omwriter);
return omwriter.getOMElement().toStringWithConsume();
} catch (Exception e) {
return "error writing adbbean "+b.getClass().toString();
}
}
-- The QName is completely made up, so it will not match the 'real' soap message, but it will at least give you a decent idea of how your message is laid out. also, I have know idea how this behave if you use an actual MTOM attachment.