public interface SshCompression
Compression interface which can be implemented to provide the SSH Transport Protocol with compression.
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFLATER
Deflation mode
|
static int |
INFLATER
Inflation mode
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
compress(byte[] data,
int start,
int len)
Compress a block of data.
|
String |
getAlgorithm()
Get the algorithm name for this compression implementation.
|
void |
init(int type,
int level)
Initialize the compression.
|
byte[] |
uncompress(byte[] data,
int start,
int len)
Uncompress a block of data.
|
static final int INFLATER
static final int DEFLATER
void init(int type,
int level)
type - the mode of the compression, should be either INFLATER or
DEFLATERlevel - the level of compressionbyte[] compress(byte[] data,
int start,
int len)
throws IOException
data - the data to compressstart - the offset of the data to compresslen - the length of the dataIOExceptionbyte[] uncompress(byte[] data,
int start,
int len)
throws IOException
data - the data to uncompressstart - the offset of the data to uncompresslen - the length of the dataIOExceptionString getAlgorithm()
Copyright © 2014. All rights reserved.