mempool

package
v2.0.48 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2024 License: Apache-2.0 Imports: 0 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultPooledBuffer

type DefaultPooledBuffer struct {
	Buf []byte
	// contains filtered or unexported fields
}

func (*DefaultPooledBuffer) GetPayload

func (buffer *DefaultPooledBuffer) GetPayload() []byte

func (*DefaultPooledBuffer) Release

func (buffer *DefaultPooledBuffer) Release()

type Pool

type Pool interface {
	AcquireBuffer() *DefaultPooledBuffer
}

func NewPool

func NewPool(poolSize int, bufSize int) Pool

func NewStrictPool

func NewStrictPool(poolSize int, bufSize int) Pool

type PooledBuffer

type PooledBuffer interface {
	GetPayload() []byte
	Release()
}

Jump to

Keyboard shortcuts

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