Avro C++
|
A no-copy input stream. More...
#include <Stream.hh>
Public Member Functions | |
virtual | ~InputStream ()=default |
Destructor. | |
virtual bool | next (const uint8_t **data, size_t *len)=0 |
Returns some of available data. More... | |
virtual void | backup (size_t len)=0 |
"Returns" back some of the data to the stream. More... | |
virtual void | skip (size_t len)=0 |
Skips number of bytes specified by len. | |
virtual size_t | byteCount () const =0 |
Returns the number of bytes read from this stream so far. More... | |
Protected Member Functions | |
InputStream ()=default | |
An empty constructor. | |
A no-copy input stream.
|
pure virtual |
"Returns" back some of the data to the stream.
The returned data must be less than what was obtained in the last call to next().
Referenced by avro::StreamReader::drain(), and avro::StreamReader::reset().
|
pure virtual |
Returns the number of bytes read from this stream so far.
All the bytes made available through next are considered to be used unless, returned back using backup.
|
pure virtual |
Returns some of available data.
Returns true if some data is available, false if no more data is available or an error has occurred.
Referenced by avro::copy(), and avro::StreamReader::fill().