Package org.globus.ftp.vanilla
Class Reply
java.lang.Object
org.globus.ftp.vanilla.Reply
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
LocalReply
Represents the FTP reply.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected int
protected int
protected boolean
protected String
static final int
static final int
static final int
static final int
static final int
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
int
getCode()
Returns the text that came with the reply, between the leading space and terminating CRLF, excluding the mentioned space and CRLF.protected static String
ignoreLeading0
(String line) GT2.0 wuftp server incorrectly inserts \0 between lines.boolean
static boolean
static boolean
isPositiveCompletion
(Reply reply) static boolean
isPositiveIntermediate
(Reply reply) static boolean
isPositivePreliminary
(Reply reply) static boolean
toString()
-
Field Details
-
POSITIVE_PRELIMINARY
public static final int POSITIVE_PRELIMINARY- See Also:
-
POSITIVE_COMPLETION
public static final int POSITIVE_COMPLETION- See Also:
-
POSITIVE_INTERMEDIATE
public static final int POSITIVE_INTERMEDIATE- See Also:
-
TRANSIENT_NEGATIVE_COMPLETION
public static final int TRANSIENT_NEGATIVE_COMPLETION- See Also:
-
PERMANENT_NEGATIVE_COMPLETION
public static final int PERMANENT_NEGATIVE_COMPLETION- See Also:
-
message
-
code
protected int code -
category
protected int category -
isMultiline
protected boolean isMultiline
-
-
Constructor Details
-
Reply
protected Reply() -
Reply
- Throws:
EOFException
- on end of streamIOException
- on I/O problemFTPReplyParseException
- if cannot parse
-
-
Method Details
-
getCategory
public int getCategory()- Returns:
- the first digit of the reply code.
-
getCode
public int getCode()- Returns:
- the reply code
-
isMultiline
public boolean isMultiline() -
getMessage
Returns the text that came with the reply, between the leading space and terminating CRLF, excluding the mentioned space and CRLF.
If the reply is multi-line, this returns the text between the leading dash "-" and the CRLF following the last line, excluding the mentioned dash and CRLF. Note that lines are separated by the local line separator [as returned by System.getProperty("line.separator")] rather than CRLF.
-
isPositivePreliminary
-
isPositiveCompletion
-
isPositiveIntermediate
-
isTransientNegativeCompletion
-
isPermanentNegativeCompletion
-
toString
-
ignoreLeading0
GT2.0 wuftp server incorrectly inserts \0 between lines. We have to deal with that.
-