Documentation ¶
Overview ¶
Package cbrotli compresses and decompresses data with C-Brotli library.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader implements io.ReadCloser by reading Brotli-encoded data from an underlying Reader.
type Writer ¶
type Writer struct {
// contains filtered or unexported fields
}
Writer implements io.WriteCloser by writing Brotli-encoded data to an underlying Writer.
func NewWriter ¶
func NewWriter(dst io.Writer, options WriterOptions) *Writer
NewWriter initializes new Writer instance. Close MUST be called to free resources.
type WriterOptions ¶
type WriterOptions struct { // Quality controls the compression-speed vs compression-density trade-offs. // The higher the quality, the slower the compression. Range is 0 to 11. Quality int // LGWin is the base 2 logarithm of the sliding window size. // Range is 10 to 24. 0 indicates automatic configuration based on Quality. LGWin int }
WriterOptions configures Writer.
Click to show internal directories.
Click to hide internal directories.