00001 #ifndef PARSE_RUN_HPP__
00002 #define PARSE_RUN_HPP__
00003
00004 #include <list>
00005 #include <string>
00006
00007 namespace cafe {
00008
00009 class Processor;
00010
00031 class ParseRun {
00032 public:
00033 ParseRun();
00034 std::list<Processor*> parse(const std::string& input);
00035 private:
00036 void init(const std::string& input);
00037 bool next();
00038 void skip_ws();
00039
00040 void ident();
00041 cafe::Processor *def();
00042
00043 void error(const char *msg);
00044 private:
00045 std::string _input;
00046 const char *_ptr;
00047 char _ch;
00048 std::string _ident;
00049 };
00050 }
00051
00052 #endif // PARSE_RUN_HPP__