public class ScpAckInfo extends Object
Modifier and Type | Field and Description |
---|---|
static int |
ERROR |
static int |
OK |
static int |
WARNING |
Constructor and Description |
---|
ScpAckInfo(int statusCode) |
ScpAckInfo(int statusCode,
String line) |
Modifier and Type | Method and Description |
---|---|
String |
getLine() |
int |
getStatusCode() |
static ScpAckInfo |
readAck(InputStream in,
Charset cs,
boolean canEof) |
<O extends OutputStream> |
send(O out,
Charset cs) |
static <O extends OutputStream> |
sendAck(O out,
Charset cs,
int level,
String message) |
static <O extends OutputStream> |
sendError(O out,
Charset cs,
String message) |
static void |
sendOk(OutputStream out,
Charset cs)
Sends
OK ACK code |
static <O extends OutputStream> |
sendWarning(O out,
Charset cs,
String message) |
String |
toString() |
void |
validateCommandStatusCode(String command,
Object location) |
public static final int OK
public static final int WARNING
public static final int ERROR
public ScpAckInfo(int statusCode)
public ScpAckInfo(int statusCode, String line)
public int getStatusCode()
public String getLine()
public <O extends OutputStream> O send(O out, Charset cs) throws IOException
IOException
public void validateCommandStatusCode(String command, Object location) throws IOException
IOException
public static ScpAckInfo readAck(InputStream in, Charset cs, boolean canEof) throws IOException
IOException
public static void sendOk(OutputStream out, Charset cs) throws IOException
OK
ACK codeout
- The target OutputStream
cs
- The Charset
to use to write the textual dataIOException
- If failed to send the ACK codepublic static <O extends OutputStream> O sendWarning(O out, Charset cs, String message) throws IOException
IOException
public static <O extends OutputStream> O sendError(O out, Charset cs, String message) throws IOException
IOException
public static <O extends OutputStream> O sendAck(O out, Charset cs, int level, String message) throws IOException
IOException
Copyright © 2008–2024 The Apache Software Foundation. All rights reserved.