You can access SOAP header information from messages received from a web services import.
Messages received from a web services import may include SOAP headers from the original SOAP message. These are placed in the headers section of the SMO in the /headers/SOAPHeader element, which may have zero or more occurrences. A SOAPHeader element is a wrapper that contains the original SOAP header as its value element. The XML namespace-qualified name of the SOAP header type appears in the SOAPHeader's name and nameSpace elements.
import commonj.sdo.DataObject; import java.util.List; DataObject smo = ... List soapHeaders = smo.getList ("/headers/SOAPHeader"); Iterator it = soapHeaders.iterator (); while (it.hasNext ()) { DataObject wrapper = (DataObject) it.next (); Object header = wrapper.get ("value"); // do something with the header }The list of SOAP headers might be an empty list.
import commonj.sdo.DataObject; import java.util.List; String headerName = ... DataObject smo = ... Object header = smo.get ("/headers/SOAPHeader[name='" + headerName + "']/value");