diff options
author | Benjamin Paassen <bpaassen@techfak.uni-bielefeld.de> | 2014-12-05 16:09:59 +0100 |
---|---|---|
committer | Benjamin Paassen <bpaassen@techfak.uni-bielefeld.de> | 2014-12-05 16:09:59 +0100 |
commit | 03b90ef542844febe6a9f99b830d67ff1c8dfb9c (patch) | |
tree | a1211d631c12bfae94bc46785fbe1cc326267976 /src/core/BufferedCharReader.hpp | |
parent | 30711f43a6cad9889ee1af8539658c4ca1f59854 (diff) | |
parent | e06e7ae19851acf5e397f579d6c8459e87086d30 (diff) |
Merge branch 'master' of somweyr.de:ousia
Diffstat (limited to 'src/core/BufferedCharReader.hpp')
-rw-r--r-- | src/core/BufferedCharReader.hpp | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/src/core/BufferedCharReader.hpp b/src/core/BufferedCharReader.hpp index bd19d4a..e7f3186 100644 --- a/src/core/BufferedCharReader.hpp +++ b/src/core/BufferedCharReader.hpp @@ -172,7 +172,6 @@ public: */ BufferedCharReader(int line = 1, int column = 1); - /** * Constructor of the buffered char reader class with a string as input. * @@ -180,7 +179,14 @@ public: * @param line is the start line. * @param column is the start column. */ - BufferedCharReader(const std::string &str, int line = 1, int column = 1); + BufferedCharReader(const std::string &str, int line, int column); + + /** + * Constructor of the buffered char reader class with a string as input. + * + * @param str is a string containing the input data. + */ + BufferedCharReader(const std::string &str); /** * Constructor of the buffered char reader class with a string as input. @@ -222,6 +228,14 @@ public: void consumePeek(); /** + * Moves the read cursor to the next non-whitespace character. Returns + * false, if the end of the stream was reached. + * + * @return false if the end of the stream was reached, false othrwise. + */ + bool consumeWhitespace(); + + /** * Resets the peek pointer to the "read" pointer. */ void resetPeek(); |