Concurrent reader/writer of bytes for use from multiple greenlets.
Supports both concurrent reading and writing.
Iterate on buffer object to read data, yielding greenlet if no data exists until self.eof has been set.
eof.set()when finished writing data via
Readers can use
read()to get any available data or
Read available data, or return None
- Return type
Write data to buffer.
data (bytes) – Data to write