net.sf.hermesftp.parser
Interface FtpCmdReader

All Superinterfaces:
Abortable, java.lang.Runnable
All Known Implementing Classes:
FtpCmdReaderThread

public interface FtpCmdReader
extends java.lang.Runnable, Abortable

Author:
Lars Behnke

Method Summary
 FtpCmdParser getParser()
          Getter method for the java bean parser.
 void setCtx(FtpSessionContext ctx)
          Sets the FTP Context of the session.
 void setParser(FtpCmdParser parser)
          Setter method for the java bean parser.
 void start()
          Starts reading command string from the previously passed input stream.
 FtpCmd waitForNextCommand(int timeout)
          Waits until another command is available.
 
Methods inherited from interface java.lang.Runnable
run
 
Methods inherited from interface net.sf.hermesftp.common.Abortable
abort, isTerminated
 

Method Detail

setCtx

void setCtx(FtpSessionContext ctx)
Sets the FTP Context of the session.

Parameters:
ctx - The context

waitForNextCommand

FtpCmd waitForNextCommand(int timeout)
                          throws FtpIllegalCmdException,
                                 java.net.SocketTimeoutException
Waits until another command is available.

Parameters:
timeout - Timeout in milliseconds.
Returns:
The next FtpCmd to handle.
Throws:
FtpIllegalCmdException - Thrown if an unknown command token is encountered.
java.net.SocketTimeoutException - Timeout error.

getParser

FtpCmdParser getParser()
Getter method for the java bean parser.

Returns:
Returns the value of the java bean parser.

setParser

void setParser(FtpCmdParser parser)
Setter method for the java bean parser.

Parameters:
parser - The value of parser to set.

start

void start()
Starts reading command string from the previously passed input stream.



Copyright © 2005-2007 Lars Behnke. All Rights Reserved.