VICI
0.11.815
Visual Chart Interpreter
|
An input stream buffer. More...
#include <sos/fdstream.h>
Public Member Functions | |
fdinbuf (int fd, bool isCloseNeeded, fdistream &owner) | |
constructor More... | |
void | close () |
Close the input file descriptor. | |
virtual | ~fdinbuf () |
destructor. | |
Protected Member Functions | |
virtual int | underflow () |
read characters from the buffer. | |
Protected Attributes | |
fdistream & | mOwner |
Our owning input stream. | |
int | mFd |
The input file descriptor. | |
bool | mIsCloseNeeded |
Whether the file descriptor needs to be closed on destruction. | |
char | mBuffer [BUFFER_SIZE+PUSHBACK_SIZE] |
Static Protected Attributes | |
static const int | BUFFER_SIZE = 8192 |
Size of buffer. | |
static const int | PUSHBACK_SIZE = 4 |
maximum number of push back characters supported | |
An input stream buffer.
An input stream buffer which reads from a file descriptor. This provides input buffering.
fdinbuf::fdinbuf | ( | int | fd, |
bool | isCloseNeeded, | ||
fdistream & | owner | ||
) |
constructor
Constructor which accepts the file descriptor to read from.
fd | the file descriptor to read from |
isCloseNeeded | a flag indicating whether the file descriptor is closed on destruction |
owner | our owning input stream |
|
protected |
Input buffer. This holds the data read and a bit more for a push-back buffer.