Documentation ¶
Overview ¶
Package cgozstd wraps the C "zstd" library.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader decompresses from the zstd format.
The zero value is not usable until Reset is called.
type ReaderRecycler ¶
type ReaderRecycler struct {
// contains filtered or unexported fields
}
ReaderRecycler can lessen the new memory allocated when calling Reader.Reset on a bound Reader.
It is not safe to use a ReaderRecycler and a Reader concurrently.
func (*ReaderRecycler) Bind ¶
func (c *ReaderRecycler) Bind(r *Reader)
Bind lets r re-use the memory that is manually managed by c. Call c.Close to free that memory.
type Writer ¶
type Writer struct {
// contains filtered or unexported fields
}
Writer compresses to the zstd format.
Compressed bytes may be buffered and not sent to the underlying io.Writer until Close is called.
The zero value is not usable until Reset is called.
type WriterRecycler ¶
type WriterRecycler struct {
// contains filtered or unexported fields
}
WriterRecycler can lessen the new memory allocated when calling Writer.Reset on a bound Writer.
It is not safe to use a WriterRecycler and a Writer concurrently.
func (*WriterRecycler) Bind ¶
func (c *WriterRecycler) Bind(w *Writer)
Bind lets w re-use the memory that is manually managed by c. Call c.Close to free that memory.