Vcsn  2.4
Be Rational
stream.cc File Reference
#include <vcsn/misc/stream.hh>
#include <cassert>
#include <cstring>
#include <istream>
#include <fstream>
#include <vcsn/misc/raise.hh>
Include dependency graph for stream.cc:

Go to the source code of this file.

Namespaces

 vcsn
 

Macros

#define CASE(Key, Value)    case Key: res = Value; i.ignore(); break
 

Functions

std::string vcsn::bracketed (std::istream &i, char lbracket, char rbracket)
 Extract the string which is here between lbracket and rbracket. More...
 
char vcsn::get_char (std::istream &i)
 Read a single char, with possible -escape support. More...
 
char vcsn::eat (std::istream &is, char c)
 Check lookahead character and advance. More...
 
const std::string & vcsn::eat (std::istream &is, const std::string &s)
 Check lookahead string and advance. More...
 
std::string vcsn::get_file_contents (const std::string &file)
 Return the contents of file. More...
 
std::shared_ptr< std::istream > vcsn::open_input_file (const std::string &file)
 Open file for reading and return its autoclosing stream. More...
 
std::shared_ptr< std::ostream > vcsn::open_output_file (const std::string &file)
 Open file for writing and return its autoclosing stream. More...
 
void vcsn::skip_space (std::istream &is)
 Ignore spaces. More...
 

Macro Definition Documentation

#define CASE (   Key,
  Value 
)    case Key: res = Value; i.ignore(); break

Referenced by vcsn::get_char().