|
class ifbitstream : public ibitstream
This class reads bits of data from input files.
This class inherits from the ibitstream
class.
Available since: 2014/02/01 version of C++ library
Constructors | |
Constructs a new bit stream that is not attached to any file. | |
Constructs a new bit stream that reads the specified file. | |
Methods | |
Closes the currently-opened file, if the stream is open. | |
Opens the specified file for reading. | |
Reads a single bit from the bit stream and returns 0 or 1 depending on the bit value. |
ifbitstream();
open
member function.
Usage:
ifbitstream stream;
ifbitstream(const char* filename); ifbitstream(string filename);
Usage:
ifbitstream stream(filename);
void close();
Usage:
stream.close();
void open(const char* filename); void open(string filename);
fail
member function.
Usage:
stream.open(filename);
int readBit();
Usage:
int bit = stream.readBit();