A std::istream with good error messages. More...
#include <Streams.hpp>
Public Member Functions | |
InputStream (const char *fn) | |
InputStream (const std::string &fn) | |
void | open (const std::string &fn) |
void | open (const char *fn) |
void | close () |
Static Public Member Functions | |
static boost::shared_ptr < std::istream > | openCompressedInputStreamByExtension (const std::string &fn) |
Returns a pointer to an InputStream or CompressedInputStream, depending on the file extension. | |
static bool | getline (std::istream &in, std::string &line) |
Retrieves the line from the given input stream, and removes a carriage return from the end if there is one. |
A std::istream with good error messages.
static bool cgatools::util::InputStream::getline | ( | std::istream & | in, | |
std::string & | line | |||
) | [static] |
Retrieves the line from the given input stream, and removes a carriage return from the end if there is one.
static boost::shared_ptr<std::istream> cgatools::util::InputStream::openCompressedInputStreamByExtension | ( | const std::string & | fn | ) | [static] |
Returns a pointer to an InputStream or CompressedInputStream, depending on the file extension.
File extensions supported: