Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnyDrainPool ¶
type AnyDrainPool interface { Type() reflect.Type Stats() DrainPoolStats Drain() int }
type AnyLinkedPool ¶
type AnyLinkedPool interface { Unwrap() any Link() *LinkedPoolLink }
type DrainPool ¶
type DrainPool[T any] struct { // contains filtered or unexported fields }
func NewDrainPool ¶
func (*DrainPool[T]) Stats ¶
func (p *DrainPool[T]) Stats() DrainPoolStats
type DrainPoolStats ¶
type DrainPoolStats struct {
New, Put, Get, Drain int64
}
type LinkedPool ¶
type LinkedPool[T any] struct { // contains filtered or unexported fields }
func NewLinkedPool ¶
func NewLinkedPool[T any](p Pool[T]) *LinkedPool[T]
func (*LinkedPool[T]) Get ¶
func (p *LinkedPool[T]) Get() T
func (*LinkedPool[T]) Link ¶
func (p *LinkedPool[T]) Link() *LinkedPoolLink
func (*LinkedPool[T]) Put ¶
func (p *LinkedPool[T]) Put(x T)
func (*LinkedPool[T]) Unwrap ¶
func (p *LinkedPool[T]) Unwrap() any
type LinkedPoolLink ¶
type LinkedPoolLink struct {
// contains filtered or unexported fields
}
func (LinkedPoolLink) Next ¶
func (l LinkedPoolLink) Next() AnyLinkedPool
func (LinkedPoolLink) Prev ¶
func (l LinkedPoolLink) Prev() AnyLinkedPool
func (*LinkedPoolLink) Unlink ¶
func (l *LinkedPoolLink) Unlink()
type SyncPool ¶
type SyncPool[T any] struct { // contains filtered or unexported fields }
func NewSyncPool ¶
type TrackingPool ¶
type TrackingPool[T any] struct { // contains filtered or unexported fields }
func NewTrackingPool ¶
func NewTrackingPool[T any](o Pool[T], k func(T) uintptr) *TrackingPool[T]
func (*TrackingPool[T]) Get ¶
func (p *TrackingPool[T]) Get() T
func (*TrackingPool[T]) Put ¶
func (p *TrackingPool[T]) Put(v T)
type WrappedSyncPool ¶
type WrappedSyncPool[T any] struct { // contains filtered or unexported fields }
func WrapSyncPool ¶
func WrapSyncPool[T any](o *sync.Pool) WrappedSyncPool[T]
func (WrappedSyncPool[T]) Get ¶
func (p WrappedSyncPool[T]) Get() T
func (WrappedSyncPool[T]) Put ¶
func (p WrappedSyncPool[T]) Put(x T)
Click to show internal directories.
Click to hide internal directories.