00001
00002
00003
00004 #ifndef DEV_W3_ORG__2001_BLINDFOLD_SRC_YACCGENERATEDPARSER_H
00005 #define DEV_W3_ORG__2001_BLINDFOLD_SRC_YACCGENERATEDPARSER_H
00006 #include "config.h"
00007
00008 #include "Parser.h"
00009 #include "ByteFIFO.h"
00010 #include "TripleSinkReifier.h"
00011 #include "generated_parser.h"
00012
00016 class YaccGeneratedParser : public Parser {
00017
00018 public:
00019
00020
00021 private: YaccGeneratedParser();
00022 public:
00023 YaccGeneratedParser(const YaccGeneratedParser& other);
00024 const YaccGeneratedParser& operator=(const YaccGeneratedParser& other);
00025 bool operator==(const YaccGeneratedParser& other) const;
00026 bool operator<(const YaccGeneratedParser& other) const;
00027 size_t hash() const;
00028 friend std::ostream& operator<<(std::ostream& s, const YaccGeneratedParser& me);
00029 std::ostream& print_to(std::ostream& stream) const;
00030 ~YaccGeneratedParser();
00031
00032
00033
00034 virtual void write(const void* byteBuffer, size_t numBytes);
00035 virtual void close();
00036
00037
00038
00039
00041 YaccGeneratedParser(parse_function entry_point) :
00042 entry_point(entry_point) { }
00043
00044 private:
00045
00046 parse_function entry_point;
00047 ByteFIFO fifo;
00048
00049
00050
00051 };
00052
00053
00054 STANDARD_EXTERNAL(YaccGeneratedParser)
00055
00056 #endif