org.mule.transport.tcp.protocols
Class EOFProtocol

java.lang.Object
  extended by org.mule.transport.tcp.protocols.AbstractByteProtocol
      extended by org.mule.transport.tcp.protocols.DirectProtocol
          extended by org.mule.transport.tcp.protocols.EOFProtocol
All Implemented Interfaces:
TcpProtocol
Direct Known Subclasses:
MuleMessageEOFProtocol, StreamingProtocol

public class EOFProtocol
extends DirectProtocol

The EOFProtocol class is an application level tcp protocol that does nothing. Reading is terminated by the stream being closed by the client.


Field Summary
 
Fields inherited from class org.mule.transport.tcp.protocols.DirectProtocol
bufferSize, UNLIMITED
 
Fields inherited from class org.mule.transport.tcp.protocols.AbstractByteProtocol
EOF, NO_STREAM, STREAM_OK
 
Constructor Summary
EOFProtocol()
           
 
Method Summary
protected  boolean isRepeat(int len, int available)
          Repeat until end of file
 
Methods inherited from class org.mule.transport.tcp.protocols.DirectProtocol
read, read, remaining
 
Methods inherited from class org.mule.transport.tcp.protocols.AbstractByteProtocol
copy, copy, createResponse, nullEmptyArray, safeRead, safeRead, write, writeByteArray
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EOFProtocol

public EOFProtocol()
Method Detail

isRepeat

protected boolean isRepeat(int len,
                           int available)
Repeat until end of file

Overrides:
isRepeat in class DirectProtocol
Parameters:
len - Amount transferred last call (-1 on EOF or socket error)
available - Amount available
Returns:
true if the transfer should continue


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