Pool provides a way to Allocate and Release Buffer objects Pools mut be concurrent-safe for calls to Get() and Put().
| 12 | // Pool provides a way to Allocate and Release Buffer objects |
| 13 | // Pools mut be concurrent-safe for calls to Get() and Put(). |
| 14 | type Pool interface { |
| 15 | Get() (Buffer, error) // Allocate a Buffer |
| 16 | Put(buf Buffer) error // Release or Reuse a Buffer |
| 17 | } |
| 18 | |
| 19 | type pool struct { |
| 20 | pool sync.Pool |
no outgoing calls
no test coverage detected
searching dependent graphs…