Documentation ¶
Index ¶
- Variables
- func AESGCM(key []byte) aeadCodec
- func HybridCompressed(compressType string, compress CompressFunc, uncompress UncompressFunc) hybridCompressedCodec
- func HybridSnappy() hybridCompressedCodec
- func HybridZstd() hybridCompressedCodec
- func NewAEADCodec(id string, newAEAD func() (cipher.AEAD, error)) aeadCodec
- func Segmented(wrapped Codec, cutSize int) segmentedCodec
- func Snappy() snappyCodec
- func Stacked(a, b Codec) stackedCodec
- func TestCodecAESGCM(t *testing.T)
- func TestCodecSnappy(t *testing.T)
- func TestCodecStacked(t *testing.T)
- func TestHybridCompressed(t *testing.T)
- func TestHybridSnappy(t *testing.T)
- func TestHybridZstd(t *testing.T)
- func TestOnion(t *testing.T)
- func TestOnion2(t *testing.T)
- func TestSegmented(t *testing.T)
- func TestSnappyStream(t *testing.T)
- func UseSnappy() (string, CompressFunc, UncompressFunc)
- func UseSnappyStream() (string, CompressFunc, UncompressFunc)
- func UseZstd() (string, CompressFunc, UncompressFunc)
- type Codec
- type CompressFunc
- type OnionCodec
- type Option
- type UncompressFunc
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultCodec = defaultCodec{}
no-op codec
View Source
var ErrCodecNotFound = errors.New("codec not found")
Functions ¶
func HybridCompressed ¶
func HybridCompressed( compressType string, compress CompressFunc, uncompress UncompressFunc, ) hybridCompressedCodec
func HybridSnappy ¶
func HybridSnappy() hybridCompressedCodec
func HybridZstd ¶
func HybridZstd() hybridCompressedCodec
func TestCodecAESGCM ¶
func TestCodecSnappy ¶
func TestCodecStacked ¶
func TestHybridCompressed ¶
func TestHybridSnappy ¶
func TestHybridZstd ¶
func TestOnion2 ¶
func TestSegmented ¶
func TestSnappyStream ¶
func UseSnappy ¶
func UseSnappy() (string, CompressFunc, UncompressFunc)
func UseSnappyStream ¶
func UseSnappyStream() (string, CompressFunc, UncompressFunc)
func UseZstd ¶
func UseZstd() (string, CompressFunc, UncompressFunc)
Types ¶
type OnionCodec ¶
type OnionCodec struct {
// contains filtered or unexported fields
}
func NewOnionCodec ¶
func NewOnionCodec( encoders []Codec, decoders []Codec, ) OnionCodec
func (OnionCodec) ID ¶
func (_ OnionCodec) ID() string
type UncompressFunc ¶
Click to show internal directories.
Click to hide internal directories.