lib

package
v1.2.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 9, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultBufferLength = 16384

	ErrTooLarge = fmt.Errorf("Too large")
)

Functions

func Log

func Log(f string, a ...interface{})

func ReleaseBuffer

func ReleaseBuffer(b *Buffer)

func ReleaseTimer

func ReleaseTimer(t *time.Timer)

func TakeTimer

func TakeTimer() *time.Timer

Types

type Buffer

type Buffer struct {
	B []byte
	// contains filtered or unexported fields
}

func TakeBuffer

func TakeBuffer() *Buffer

func (*Buffer) Allocate

func (b *Buffer) Allocate(n int)

func (*Buffer) Append

func (b *Buffer) Append(v []byte)

func (*Buffer) AppendByte

func (b *Buffer) AppendByte(v byte)

func (*Buffer) Extend

func (b *Buffer) Extend(n int) []byte

func (*Buffer) Len

func (b *Buffer) Len() int

func (*Buffer) ReadDataFrom

func (b *Buffer) ReadDataFrom(r io.Reader) (int, error)

func (*Buffer) Reset

func (b *Buffer) Reset()

func (*Buffer) Set

func (b *Buffer) Set(v []byte)

func (*Buffer) String

func (b *Buffer) String() string

func (*Buffer) WriteDataTo

func (b *Buffer) WriteDataTo(w io.Writer) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL