Inheritance diagram for code::InputStream:
On the CODE system, there are two subclasses of OutputStream: AIStream which provides an ASCII stream BOIStream which provides a portable binary representation
Typically, most classes will provide a friend stream << representation. That representation will then work in providing both types of streamed output.
float and double are not provided in this abstract class because there is no portable way to represent them in binary; you will find those operators in AIStream only.
Public Member Functions | |
virtual InputStream & | operator>> (bool &)=0 throw ( std::string ) |
Read a string from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (char &)=0 throw ( std::string ) |
Read a char from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (unsigned char &)=0 throw ( std::string ) |
Read an unsigned char from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (int16_t &)=0 throw ( std::string ) |
Read a 16-bit signed integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (uint16_t &)=0 throw ( std::string ) |
Read a 16-bit unsigned integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (int32_t &)=0 throw ( std::string ) |
Read a 32-bit signed integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (uint32_t &)=0 throw ( std::string ) |
Read a 32-bit unsigned integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (int64_t &)=0 throw ( std::string ) |
Read a 64-bit signed integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (uint64_t &)=0 throw ( std::string ) |
Read a 64-bit unsigned integer from the stream, throwing an error message on failure. | |
virtual InputStream & | operator>> (float &)=0 throw ( std::string ) |
Extract a float from the input stream. | |
virtual InputStream & | operator>> (double &)=0 throw ( std::string ) |
Extract a double from the input stream. | |
virtual InputStream & | operator>> (std::string &)=0 throw ( std::string ) |
Extract a std::string from the input stream. | |
virtual | ~InputStream () |
Virtual destructor for subclassing. |
virtual code::InputStream::~InputStream | ( | ) | [inline, virtual] |
Virtual destructor for subclassing.
virtual InputStream& code::InputStream::operator>> | ( | std::string & | ) | throw ( std::string ) [pure virtual] |
Extract a std::string from the input stream.
If an error occurs while reading from the stream, an explanatory std::string will be thrown and the reference argument will be unchanged.
std::string |
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | double & | ) | throw ( std::string ) [pure virtual] |
Extract a double from the input stream.
WARNING: doubles are not really very portable. If you are defining a new data format, please use int/long, multiplying your value by the needed precision. This is for those formats that do use double and can not be helped.
If an error occurs while reading from the stream, an explanatory std::string will be thrown and the reference argument will be unchanged.
std::string |
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | float & | ) | throw ( std::string ) [pure virtual] |
Extract a float from the input stream.
WARNING: doubles are not really very portable. If you are defining a new data format, please use int/long, multiplying your value by the needed precision. This is for those formats that do use double and can not be helped.
If an error occurs while reading from the stream, an explanatory std::string will be thrown and the reference argument will be unchanged.
std::string |
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | uint64_t & | ) | throw ( std::string ) [pure virtual] |
Read a 64-bit unsigned integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | int64_t & | ) | throw ( std::string ) [pure virtual] |
Read a 64-bit signed integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | uint32_t & | ) | throw ( std::string ) [pure virtual] |
Read a 32-bit unsigned integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | int32_t & | ) | throw ( std::string ) [pure virtual] |
Read a 32-bit signed integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | uint16_t & | ) | throw ( std::string ) [pure virtual] |
Read a 16-bit unsigned integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | int16_t & | ) | throw ( std::string ) [pure virtual] |
Read a 16-bit signed integer from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | unsigned char & | ) | throw ( std::string ) [pure virtual] |
Read an unsigned char from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | char & | ) | throw ( std::string ) [pure virtual] |
Read a char from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.
virtual InputStream& code::InputStream::operator>> | ( | bool & | ) | throw ( std::string ) [pure virtual] |
Read a string from the stream, throwing an error message on failure.
Implemented in code::AIStream, and code::BOIStream.