extra library

Extra / advanced helpers.

This entrypoint contains non-default APIs that are useful in high-throughput systems (e.g. buffer pooling). These APIs are designed to be safe-by-default but require explicit ownership decisions (e.g. release vs retain).

  • Keeping a PooledBytes lease is safe (owned bytes).
  • Calling release() enables reuse; use-after-release fails fast.

Classes

BufferPool
A pool of reusable byte buffers.
PooledBytes
A leased byte buffer containing a decoded frame.
SimpleBufferPool
A simple power-of-two bucketed buffer pool.

Extensions

ExtraFramingX on Stream<List<int>>