Skip to content

Version 1.3.0

Choose a tag to compare

@StormBytePP StormBytePP released this 20 Sep 11:46
· 110 commits to master since this release

[Summary]

StormByte Buffer is the byte-buffer module of the StormByte C++ suite.

It depends on StormByte Base and optionally StormByte Logger. This repository is not Base, Config, Crypto, Database, Logger, Multimedia, Network or System.

Public headers under StormByte/buffer/ cover FIFO, SharedFIFO, Ring, Producer/Consumer, Hopper, Sink, Bridge and Pipeline.

If you landed here from a release link and have not read the tree:

  • What this module is, how to build it, and short examples: README.md
  • License: GNU Lesser General Public License version 3 or later, LICENSE

Added

  • Sink::Keys, Sink::Buckets, Sink::Contains, Sink::Empty(key), Sink::EoF(key) and Sink::Ready(key). Query only. Missing key: Empty is true, EoF/Ready/Contains are false, Buckets is the wired count.
  • Sink::Pop(int key). Reads that hopper only. Waits until the key is wired or the Sink is closed. Empty hopper returns default T (same as Hopper::Pop). Does not interpret the key.
  • Hopper::Writers, Hopper::Ready and Hopper::Front. Front copies the next item and does not dequeue; requires std::copy_constructible<T> (shared_ptr). Not a deep copy of the payload. Writers is the live writer count (starts at 1).

Tests

  • test_hopper_front_peek, test_hopper_writers_and_ready.
  • test_sink_pop_key, test_sink_query_unwired, test_sink_query_wired.
  • Hopper and Sink test files ordered by section name, then by test name.