public class DefaultSOAP2MessageGenerator extends java.lang.Object implements SOAP2MessageGenerator
| Modifier and Type | Class and Description |
|---|---|
protected static class |
DefaultSOAP2MessageGenerator.InlineMessageReceiver |
| Modifier and Type | Field and Description |
|---|---|
protected static DefaultMessageDiscarder |
DEFAULT_DISCARDER |
protected MessageParser |
msgParser |
protected XmlPullParser |
parser |
| Constructor and Description |
|---|
DefaultSOAP2MessageGenerator()
Standard constructor
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
beforeReceive(MessageReceiver to,
InvokeMessage msg,
ConnectionInfo connectionInfo)
This method is called before invoke messages are forwarded.
|
protected void |
beforeReceive(MessageReceiver to,
Message msg,
ConnectionInfo connectionInfo)
This method is called before messages other than discovery or invoke messages are forwarded.
|
protected void |
beforeReceive(MessageReceiver to,
SignableMessage msg,
ConnectionInfo connectionInfo)
This method is called before discovery messages are forwarded.
|
protected ElementParser |
createNewElementParser(XmlPullParser parser2,
URI fromURI)
Added by SSch.
|
protected void |
deliverBody(SOAPHeader header,
ElementParser parser,
MessageReceiver to,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId) |
void |
deliverMessage(java.io.InputStream in,
MessageReceiver to,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId)
Delivers a single incoming message obtained from reading
in to to. |
void |
deliverMessage(java.io.InputStream in,
MessageReceiver to,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId,
DefaultMessageDiscarder discarder,
Message request)
Delivers a single incoming message obtained from reading
in to to. |
Message |
generateMessage(java.io.InputStream in,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId)
This method generates message objects from the given input stream.
|
static DefaultMessageDiscarder |
getDefaultMessageDiscarder() |
protected XmlPullParser |
getParser()
Added by SSch in order to allow override of the ParserImpl
|
protected boolean |
handleMessage(ElementParser parser,
SOAPHeader header,
MessageReceiver to,
ConnectionInfo connectionInfo) |
protected void |
sendInvokeMessageToReceiver(MessageReceiver to,
InvokeMessage msg,
ConnectionInfo connectionInfo) |
static void |
setMessageDiscarder(DefaultMessageDiscarder newDiscarder) |
protected static final DefaultMessageDiscarder DEFAULT_DISCARDER
protected XmlPullParser parser
protected MessageParser msgParser
public DefaultSOAP2MessageGenerator()
public static DefaultMessageDiscarder getDefaultMessageDiscarder()
public static void setMessageDiscarder(DefaultMessageDiscarder newDiscarder)
public void deliverMessage(java.io.InputStream in,
MessageReceiver to,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId)
SOAP2MessageGeneratorin to to.
Uses default DefaultMessageDiscarder.deliverMessage in interface SOAP2MessageGeneratorin - the stream from which to parse the messageto - the receiver to deliver the message toconnectionInfo - transport-related information attached to the message being received; it is passed directly to one of the
receive() methods of the specified MessageReceiver touniqueAttachmentContextId - a unique string to identify the attachment context or null if the message does not contain
an attachmentpublic Message generateMessage(java.io.InputStream in, ConnectionInfo connectionInfo, java.lang.String uniqueAttachmentContextId) throws java.lang.Exception
SOAP2MessageGeneratorgenerateMessage in interface SOAP2MessageGeneratorin - the stream to read input fromjava.lang.Exceptionpublic void deliverMessage(java.io.InputStream in,
MessageReceiver to,
ConnectionInfo connectionInfo,
java.lang.String uniqueAttachmentContextId,
DefaultMessageDiscarder discarder,
Message request)
SOAP2MessageGeneratorin to to.deliverMessage in interface SOAP2MessageGeneratorin - the stream from which to parse the messageto - the receiver to deliver the message toconnectionInfo - transport-related information attached to the message being received; it is passed directly to one of the
receive() methods of the specified MessageReceiver touniqueAttachmentContextId - a unique string to identify the attachment context or null if the message does not contain
an attachmentdiscarder - decides whether to deliver or drop the messageprotected void deliverBody(SOAPHeader header, ElementParser parser, MessageReceiver to, ConnectionInfo connectionInfo, java.lang.String uniqueAttachmentContextId) throws XmlPullParserException, java.io.IOException, UnexpectedMessageException, MissingElementException, UnexpectedElementException, VersionMismatchException
XmlPullParserExceptionjava.io.IOExceptionUnexpectedMessageExceptionMissingElementExceptionUnexpectedElementExceptionVersionMismatchExceptionprotected void sendInvokeMessageToReceiver(MessageReceiver to, InvokeMessage msg, ConnectionInfo connectionInfo)
to - connectionInfo - msg - protected void beforeReceive(MessageReceiver to, InvokeMessage msg, ConnectionInfo connectionInfo)
to - msg - connectionInfo - protected void beforeReceive(MessageReceiver to, SignableMessage msg, ConnectionInfo connectionInfo)
to - msg - connectionInfo - protected void beforeReceive(MessageReceiver to, Message msg, ConnectionInfo connectionInfo)
to - msg - connectionInfo - protected boolean handleMessage(ElementParser parser, SOAPHeader header, MessageReceiver to, ConnectionInfo connectionInfo) throws XmlPullParserException, java.io.IOException, VersionMismatchException
XmlPullParserExceptionjava.io.IOExceptionVersionMismatchExceptionprotected ElementParser createNewElementParser(XmlPullParser parser2, URI fromURI)
parser2 - protected XmlPullParser getParser()