Documentation
¶
Index ¶
Constants ¶
View Source
const ( AutoExpand = -1 MinRead = 1 << 9 MaxRead = 1 << 17 ResetOffMark = -1 DefaultSize = 1 << 4 MaxBufferLength = 1 << 20 MaxThreshold = 1 << 22 )
Variables ¶
Functions ¶
Types ¶
type ByteBufferPoolContainer ¶
type ByteBufferPoolContainer struct {
// contains filtered or unexported fields
}
func NewByteBufferPoolContainer ¶
func NewByteBufferPoolContainer() *ByteBufferPoolContainer
func (*ByteBufferPoolContainer) Reset ¶
func (c *ByteBufferPoolContainer) Reset()
func (*ByteBufferPoolContainer) Take ¶
func (c *ByteBufferPoolContainer) Take(size int) *[]byte
type IoBuffer ¶
keep this alias for compatbile. if you write new code, use api.IoBuffer instead.
func NewIoBufferBytes ¶
func NewIoBufferEOF ¶
func NewIoBufferEOF() IoBuffer
func NewIoBufferString ¶
func NewPipeBuffer ¶
type IoBufferPool ¶
type IoBufferPool struct {
// contains filtered or unexported fields
}
IoBufferPool is Iobuffer Pool
func (*IoBufferPool) GetIoBuffer ¶
func (p *IoBufferPool) GetIoBuffer(size int) IoBuffer
GetIoBuffer returns IoBuffer from pool
func (*IoBufferPool) PutIoBuffer ¶
func (p *IoBufferPool) PutIoBuffer(buf IoBuffer) error
PutIoBuffer returns IoBuffer to pool
Click to show internal directories.
Click to hide internal directories.