Documentation ¶
Index ¶
- type CompressedInputStream
- func (this *CompressedInputStream) AddListener(bl kanzi.Listener) bool
- func (this *CompressedInputStream) Close() error
- func (this *CompressedInputStream) GetRead() uint64
- func (this *CompressedInputStream) Read(block []byte) (int, error)
- func (this *CompressedInputStream) RemoveListener(bl kanzi.Listener) bool
- type CompressedOutputStream
- func (this *CompressedOutputStream) AddListener(bl kanzi.Listener) bool
- func (this *CompressedOutputStream) Close() error
- func (this *CompressedOutputStream) GetWritten() uint64
- func (this *CompressedOutputStream) RemoveListener(bl kanzi.Listener) bool
- func (this *CompressedOutputStream) Write(block []byte) (int, error)
- type IOError
- type NullOutputStream
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CompressedInputStream ¶
type CompressedInputStream struct {
// contains filtered or unexported fields
}
CompressedInputStream a Reader that reads compressed data from an InputBitStream.
func NewCompressedInputStream ¶
func NewCompressedInputStream(is io.ReadCloser, jobs uint) (*CompressedInputStream, error)
NewCompressedInputStream creates a new instance of CompressedInputStream
func NewCompressedInputStreamWithCtx ¶
func NewCompressedInputStreamWithCtx(is io.ReadCloser, ctx map[string]interface{}) (*CompressedInputStream, error)
NewCompressedInputStreamWithCtx creates a new instance of CompressedInputStream using a map of parameters
func (*CompressedInputStream) AddListener ¶
func (this *CompressedInputStream) AddListener(bl kanzi.Listener) bool
AddListener adds an event listener to this input stream. Returns true if the listener has been added.
func (*CompressedInputStream) Close ¶
func (this *CompressedInputStream) Close() error
Close reads the buffered data intto the input stream and releases resources. Close makes the bitstream unavailable for further reads. Idempotent
func (*CompressedInputStream) GetRead ¶
func (this *CompressedInputStream) GetRead() uint64
GetRead returns the number of bytes read so far
func (*CompressedInputStream) Read ¶
func (this *CompressedInputStream) Read(block []byte) (int, error)
Read reads up to len(block) bytes into block. It returns the number of bytes read (0 <= n <= len(block)) and any error encountered.
func (*CompressedInputStream) RemoveListener ¶
func (this *CompressedInputStream) RemoveListener(bl kanzi.Listener) bool
RemoveListener removes an event listener from this input stream. Returns true if the listener has been removed.
type CompressedOutputStream ¶
type CompressedOutputStream struct {
// contains filtered or unexported fields
}
CompressedOutputStream a Writer that writes compressed data to an OutputBitStream.
func NewCompressedOutputStream ¶
func NewCompressedOutputStream(os io.WriteCloser, codec, transform string, blockSize, jobs uint, checksum bool) (*CompressedOutputStream, error)
NewCompressedOutputStream creates a new instance of CompressedOutputStream
func NewCompressedOutputStreamWithCtx ¶
func NewCompressedOutputStreamWithCtx(os io.WriteCloser, ctx map[string]interface{}) (*CompressedOutputStream, error)
NewCompressedOutputStreamWithCtx creates a new instance of CompressedOutputStream using a map of parameters
func (*CompressedOutputStream) AddListener ¶
func (this *CompressedOutputStream) AddListener(bl kanzi.Listener) bool
AddListener adds an event listener to this output stream. Returns true if the listener has been added.
func (*CompressedOutputStream) Close ¶
func (this *CompressedOutputStream) Close() error
Close writes the buffered data to the output stream then writes a final empty block and releases resources. Close makes the bitstream unavailable for further writes. Idempotent.
func (*CompressedOutputStream) GetWritten ¶
func (this *CompressedOutputStream) GetWritten() uint64
GetWritten returns the number of bytes written so far
func (*CompressedOutputStream) RemoveListener ¶
func (this *CompressedOutputStream) RemoveListener(bl kanzi.Listener) bool
RemoveListener removes an event listener from this output stream. Returns true if the listener has been removed.
func (*CompressedOutputStream) Write ¶
func (this *CompressedOutputStream) Write(block []byte) (int, error)
Write writes len(block) bytes from block to the underlying data stream. It returns the number of bytes written from block (0 <= n <= len(block)) and any error encountered that caused the write to stop early.
type IOError ¶
type IOError struct {
// contains filtered or unexported fields
}
IOError an extended error containing a message and a code value
func NewIOError ¶
NewIOError creates a new instance of IOError
type NullOutputStream ¶
type NullOutputStream struct {
// contains filtered or unexported fields
}
NullOutputStream similar to io.Discard but implements io.WriteCloser
func NewNullOutputStream ¶
func NewNullOutputStream() (*NullOutputStream, error)
NewNullOutputStream creates an instance of NullOutputStream
func (*NullOutputStream) Close ¶
func (this *NullOutputStream) Close() error
Close makes the stream unavailable for further writes