Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Compressors = map[CompressType]Compressor{ Raw: RawCompressor{}, Gzip: GzipCompressor{}, Snappy: SnappyCompressor{}, Zlib: ZlibCompressor{}, }
Compressors which supported by rpc
Functions ¶
This section is empty.
Types ¶
type CompressType ¶
type CompressType uint16
CompressType type of compressions supported by rpc
const ( Raw CompressType = iota Gzip Snappy Zlib )
type Compressor ¶
Compressor is interface, each compressor has Zip and Unzip functions
type GzipCompressor ¶
type GzipCompressor struct {
}
Zlib 是一个广泛使用的压缩库,基于 DEFLATE 算法,具有良好的压缩比和较快的速度。 GzipCompressor implements the Compressor interface
type RawCompressor ¶
type RawCompressor struct {
}
RawCompressor implements the Compressor interface
type SnappyCompressor ¶
type SnappyCompressor struct {
}
Snappy 是由 Google 开发的一种压缩库,专注于高压缩速度和合理的压缩比。Snappy 并不追求最小化的压缩率,而是优先保证较高的压缩和解压速度,使其非常适合需要快速处理大量数据的场景。 SnappyCompressor implements the Compressor interface
type ZlibCompressor ¶
type ZlibCompressor struct {
}
ZlibCompressor implements the Compressor interface
Click to show internal directories.
Click to hide internal directories.