31 #ifndef FILE_READER_INCLUDED 32 #define FILE_READER_INCLUDED 41 #include <sigc++/sigc++.h> 136 bool open(
const std::string& name);
150 bool isOpen(
void)
const {
return (fd != -1); }
159 int read(
void *buf,
int len);
171 void onDataAvail(
FdWatch *watch);
172 bool fillBuffer(
void);
173 int bytesInBuffer(
void)
const;
bool isOpen(void) const
Check if a file is currently opened.
FileReader(int buf_size)
Constuctor.
bool open(const std::string &name)
Open a file for binary reading.
bool close(void)
Close a previously opened file.
~FileReader(void)
Destructor.
int read(void *buf, int len)
Read data from a previously opened file.
A class for watching file descriptors.
Namespace for the asynchronous programming classes.