summaryrefslogtreecommitdiff
path: root/src/core/parser/stack/Stack.hpp
diff options
context:
space:
mode:
authorBenjamin Paassen <bpaassen@techfak.uni-bielefeld.de>2015-03-02 15:58:55 +0100
committerBenjamin Paassen <bpaassen@techfak.uni-bielefeld.de>2015-03-02 15:58:55 +0100
commit24c7a8d1e62dc52298ea1abdc8b44d70fff94b54 (patch)
treec82a161ce02e177b6be5e63a65c5a2f42eecf2e6 /src/core/parser/stack/Stack.hpp
parent4b5f37d07e4e691848b243ae795bb59893a6379c (diff)
parent5b81f755a5303c3eab05c605711ecca32c071b6d (diff)
Merge branch 'astoecke_tokens' of somweyr.de:ousia into astoecke_tokens
Conflicts: application/src/core/parser/stack/Callbacks.hpp application/src/core/parser/stack/Handler.hpp
Diffstat (limited to 'src/core/parser/stack/Stack.hpp')
-rw-r--r--src/core/parser/stack/Stack.hpp19
1 files changed, 6 insertions, 13 deletions
diff --git a/src/core/parser/stack/Stack.hpp b/src/core/parser/stack/Stack.hpp
index e1173d0..de281d4 100644
--- a/src/core/parser/stack/Stack.hpp
+++ b/src/core/parser/stack/Stack.hpp
@@ -42,6 +42,7 @@ class Variant;
namespace parser_stack {
// Forward declarations
+class ParserCallbacks;
class StackImpl;
class State;
@@ -63,11 +64,13 @@ public:
/**
* Creates a new instance of the Stack class.
*
+ * @param parser is an implementation of the ParserCallbacks instance to
+ * which certain calls are directed.
* @param ctx is the parser context the parser stack is working on.
* @param states is a map containing the command names and pointers at the
* corresponding State instances.
*/
- Stack(ParserContext &ctx,
+ Stack(ParserCallbacks &parser, ParserContext &ctx,
const std::multimap<std::string, const State *> &states);
/**
@@ -81,7 +84,7 @@ public:
* @return the state of the currently active Handler instance or
* States::None if no handler is on the stack.
*/
- const State &currentState();
+ const State &currentState() const;
/**
* Returns the command name that is currently being handled.
@@ -89,7 +92,7 @@ public:
* @return the name of the command currently being handled by the active
* Handler instance or an empty string if no handler is currently active.
*/
- std::string currentCommandName();
+ std::string currentCommandName() const;
/**
* Function that should be called whenever a new command is reached.
@@ -154,16 +157,6 @@ public:
* that should be read.
*/
void data(const TokenizedData &data);
-
- /**
- * Function that shuold be called whenever character data is found in the
- * input stream. The given string variant is converted into a TokenizedData
- * instance internally.
- *
- * @param stringData is a string variant containing the data that has been
- * found.
- */
- void data(const Variant &stringData);
};
}
}