Class ScpAckInfo
- java.lang.Object
-
- org.apache.sshd.scp.common.helpers.ScpAckInfo
-
public class ScpAckInfo extends Object
- Author:
- Apache MINA SSHD Project
-
-
Constructor Summary
Constructors Constructor Description ScpAckInfo(int statusCode)
ScpAckInfo(int statusCode, String line)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getLine()
int
getStatusCode()
static ScpAckInfo
readAck(InputStream in, Charset cs, boolean canEof)
<O extends OutputStream>
Osend(O out, Charset cs)
static <O extends OutputStream>
OsendAck(O out, Charset cs, int level, String message)
static <O extends OutputStream>
OsendError(O out, Charset cs, String message)
static void
sendOk(OutputStream out, Charset cs)
SendsOK
ACK codestatic <O extends OutputStream>
OsendWarning(O out, Charset cs, String message)
String
toString()
void
validateCommandStatusCode(String command, Object location)
-
-
-
Field Detail
-
OK
public static final int OK
- See Also:
- Constant Field Values
-
WARNING
public static final int WARNING
- See Also:
- Constant Field Values
-
ERROR
public static final int ERROR
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ScpAckInfo
public ScpAckInfo(int statusCode)
-
ScpAckInfo
public ScpAckInfo(int statusCode, String line)
-
-
Method Detail
-
getStatusCode
public int getStatusCode()
-
getLine
public String getLine()
-
send
public <O extends OutputStream> O send(O out, Charset cs) throws IOException
- Throws:
IOException
-
validateCommandStatusCode
public void validateCommandStatusCode(String command, Object location) throws IOException
- Throws:
IOException
-
readAck
public static ScpAckInfo readAck(InputStream in, Charset cs, boolean canEof) throws IOException
- Throws:
IOException
-
sendOk
public static void sendOk(OutputStream out, Charset cs) throws IOException
SendsOK
ACK code- Parameters:
out
- The targetOutputStream
cs
- TheCharset
to use to write the textual data- Throws:
IOException
- If failed to send the ACK code
-
sendWarning
public static <O extends OutputStream> O sendWarning(O out, Charset cs, String message) throws IOException
- Throws:
IOException
-
sendError
public static <O extends OutputStream> O sendError(O out, Charset cs, String message) throws IOException
- Throws:
IOException
-
sendAck
public static <O extends OutputStream> O sendAck(O out, Charset cs, int level, String message) throws IOException
- Throws:
IOException
-
-