Modifier and Type | Field and Description |
---|---|
static int |
BAD
The reply code indicating command rejection.
|
static int |
CONT
The reply code indicating command continuation.
|
static int |
NO
The reply code indicating failure of an operation.
|
static int |
OK
The reply code indicating success of an operation.
|
static int |
PARTIAL
The reply code indicating a partial response.
|
Modifier and Type | Method and Description |
---|---|
static int |
getReplyCode(String line)
Intepret the String reply code - OK, NO, BAD - in a tagged response as a integer.
|
static int |
getUntaggedReplyCode(String line)
Intepret the String reply code - OK, NO, BAD - in an untagged response as a integer.
|
static boolean |
isContinuation(int replyCode)
Checks if the reply line is a continuation, i.e.
|
static boolean |
isContinuation(String line)
Checks if the reply line is a continuation, i.e.
|
static boolean |
isSuccess(int replyCode)
Checks whether the reply code indicates success or not
|
static boolean |
isUntagged(String line)
Checks if the reply line is untagged - e.g.
|
static int |
literalCount(String line)
Checks if the line introduces a literal, i.e.
|
public static final int OK
public static final int NO
public static final int BAD
public static final int CONT
public static final int PARTIAL
public static boolean isUntagged(String line)
line
- to be checkedtrue
if the line is untaggedpublic static boolean isContinuation(String line)
line
- the line to be checkedtrue
if the line is untaggedpublic static int getReplyCode(String line) throws IOException
line
- the tagged line to be checkedOK
or NO
or BAD
or CONT
IOException
- if the input has an unexpected formatpublic static int literalCount(String line)
line
- the line to checkpublic static int getUntaggedReplyCode(String line) throws IOException
line
- the untagged line to be checkedOK
or NO
or BAD
or CONT
IOException
- if the input has an unexpected formatpublic static boolean isSuccess(int replyCode)
replyCode
- the code to checktrue
if the code equals OK
public static boolean isContinuation(int replyCode)
replyCode
- the code to be checkedtrue
if the response was a continuationCopyright © 2001–2016 The Apache Software Foundation. All rights reserved.