org.mule.providers.tcp
Class TcpMessageReceiver.TcpStreamWorker

java.lang.Object
  extended by org.mule.providers.AbstractReceiverWorker
      extended by org.mule.providers.AbstractReceiverResourceWorker
          extended by org.mule.providers.tcp.TcpMessageReceiver.TcpWorker
              extended by org.mule.providers.tcp.TcpMessageReceiver.TcpStreamWorker
All Implemented Interfaces:
Runnable, javax.resource.spi.work.Work, Disposable
Direct Known Subclasses:
SslMessageReceiver.SslStreamWorker
Enclosing class:
TcpMessageReceiver

protected class TcpMessageReceiver.TcpStreamWorker
extends TcpMessageReceiver.TcpWorker


Field Summary
 
Fields inherited from class org.mule.providers.tcp.TcpMessageReceiver.TcpWorker
closed, dataIn, dataOut, protocol, socket
 
Fields inherited from class org.mule.providers.AbstractReceiverResourceWorker
resource
 
Fields inherited from class org.mule.providers.AbstractReceiverWorker
endpoint, messages, out, receiver
 
Constructor Summary
TcpMessageReceiver.TcpStreamWorker(Socket socket, AbstractMessageReceiver receiver)
           
 
Method Summary
protected  Object getNextMessage(Object resource)
          The method used to read the next message from the underlying transport.
protected  void handleResults(List messages)
          When Mule has finished processing the current messages, there may be zero or more messages to process by the receiver if request/response messaging is being used.
 
Methods inherited from class org.mule.providers.tcp.TcpMessageReceiver.TcpWorker
bindTransaction, dispose, preRouteMuleMessage, release
 
Methods inherited from class org.mule.providers.AbstractReceiverResourceWorker
doRun
 
Methods inherited from class org.mule.providers.AbstractReceiverWorker
handleException, postProcessMessage, preProcessMessage, run
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TcpMessageReceiver.TcpStreamWorker

public TcpMessageReceiver.TcpStreamWorker(Socket socket,
                                          AbstractMessageReceiver receiver)
                                   throws IOException
Throws:
IOException
Method Detail

getNextMessage

protected Object getNextMessage(Object resource)
                         throws Exception
Description copied from class: AbstractReceiverResourceWorker
The method used to read the next message from the underlying transport.

Overrides:
getNextMessage in class TcpMessageReceiver.TcpWorker
Parameters:
resource - the resource to read from, this may be a socket, a directory or some higher level representation.
Returns:
the message read from the resource. This can be raw data such as a byte[] or a UMOMessageAdapter.
Throws:
Exception

handleResults

protected void handleResults(List messages)
                      throws Exception
Description copied from class: AbstractReceiverWorker
When Mule has finished processing the current messages, there may be zero or more messages to process by the receiver if request/response messaging is being used. The result(s) should be passed back to the callee.

Overrides:
handleResults in class TcpMessageReceiver.TcpWorker
Parameters:
messages - a list of messages. This argument will not be null
Throws:
Exception


Copyright © 2003-2008 MuleSource, Inc.. All Rights Reserved.