Versions in this module Expand all Collapse all v2 v2.7.3 Dec 10, 2024 Changes in this version + type ExpireFunc func(interface{}) + type NewFunc func() (interface{}, error) + type Pool struct + ExpireFunc func(interface{}) + NewFunc func() (interface{}, error) + TTL time.Duration + func New(ttl time.Duration, newFunc NewFunc, expireFunc ...ExpireFunc) *Pool + func (p *Pool) Clear() + func (p *Pool) Close() + func (p *Pool) Get() (interface{}, error) + func (p *Pool) MustPut(value interface{}) + func (p *Pool) Put(value interface{}) error + func (p *Pool) Size() int