org.neociclo.odetteftp.protocol
Class DefaultStartFileResponse

java.lang.Object
  extended by org.neociclo.odetteftp.protocol.DefaultStartFileResponse
All Implemented Interfaces:
StartFileResponse

public class DefaultStartFileResponse
extends Object
implements StartFileResponse

Version:
$Rev: 788 $ $Date: 2010-10-18 15:13:22 -0200 (Mon, 18 Oct 2010) $
Author:
Rafael Marins

Constructor Summary
protected DefaultStartFileResponse(boolean accepted, AnswerReason reason, String reasonText, boolean retryLater)
           
protected DefaultStartFileResponse(boolean accepted, long restartOffset)
           
 
Method Summary
 boolean accepted()
           
 File getFile()
           
 AnswerReason getReason()
           
 String getReasonText()
           
 long getRestartOffset()
           
static DefaultStartFileResponse negativeStartFileAnswer()
           
static DefaultStartFileResponse negativeStartFileAnswer(AnswerReason reason, String reasonText, boolean retryLater)
           
static DefaultStartFileResponse positiveStartFileAnswer(File saveTo)
           
static DefaultStartFileResponse positiveStartFileAnswer(File saveTo, long restartOffset)
           
 boolean retryLater()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultStartFileResponse

protected DefaultStartFileResponse(boolean accepted,
                                   long restartOffset)

DefaultStartFileResponse

protected DefaultStartFileResponse(boolean accepted,
                                   AnswerReason reason,
                                   String reasonText,
                                   boolean retryLater)
Method Detail

positiveStartFileAnswer

public static DefaultStartFileResponse positiveStartFileAnswer(File saveTo)

positiveStartFileAnswer

public static DefaultStartFileResponse positiveStartFileAnswer(File saveTo,
                                                               long restartOffset)

negativeStartFileAnswer

public static DefaultStartFileResponse negativeStartFileAnswer()

negativeStartFileAnswer

public static DefaultStartFileResponse negativeStartFileAnswer(AnswerReason reason,
                                                               String reasonText,
                                                               boolean retryLater)

accepted

public boolean accepted()
Specified by:
accepted in interface StartFileResponse
Returns:

getReason

public AnswerReason getReason()
Specified by:
getReason in interface StartFileResponse
Returns:

getReasonText

public String getReasonText()
Specified by:
getReasonText in interface StartFileResponse

getRestartOffset

public long getRestartOffset()
Specified by:
getRestartOffset in interface StartFileResponse
Returns:

retryLater

public boolean retryLater()
Specified by:
retryLater in interface StartFileResponse
Returns:

getFile

public File getFile()
Specified by:
getFile in interface StartFileResponse
Returns:


ACCORD