Source-highlight Library
/home/bettini/work/source-highlight/src-highlite/lib/srchilite/langelemsprinter.hpp
00001 //
00002 // C++ Interface: langelemsprinter
00003 //
00004 // Description:
00005 //
00006 //
00007 // Author: Lorenzo Bettini <http://www.lorenzobettini.it>, (C) 2006
00008 //
00009 // Copyright: See COPYING file that comes with this distribution
00010 //
00011 //
00012 #ifndef LANGELEMSPRINTER_H
00013 #define LANGELEMSPRINTER_H
00014 
00015 #include <set>
00016 #include <string>
00017 #include <ostream>
00018 
00019 namespace srchilite {
00020 
00026 // doublecpp: forward declarations, DO NOT MODIFY
00027 class LangElem; // file: langelem.h
00028 class LangElems; // file: langelems.h
00029 class NamedSubExpsLangElem; // file: namedsubexpslangelem.h
00030 class StateLangElem; // file: statelangelem.h
00031 // doublecpp: end, DO NOT MODIFY
00032 
00033 #line 26 "langelemsprinter.h"
00034 class LangElemsPrinter
00035 {
00036     typedef std::set<std::string> SetOfElements;
00037     SetOfElements setOfElements;
00038 
00039 public:
00040     LangElemsPrinter();
00041 
00042     virtual ~LangElemsPrinter();
00043 
00050     void print(const LangElems *elems, std::ostream &os);
00051 
00052 protected:
00053 // doublecpp: method branches, DO NOT MODIFY
00054 #line 46 "langelemsprinter.h"
00055 virtual void collect(const StateLangElem * elem);
00056 #line 47 "langelemsprinter.h"
00057 virtual void collect(const LangElem * elem);
00058 #line 48 "langelemsprinter.h"
00059 virtual void collect(const LangElems * elem);
00060 #line 49 "langelemsprinter.h"
00061 virtual void collect(const NamedSubExpsLangElem * elem);
00062 public:
00063 void _forward_collect(const LangElem * elem)
00064 {
00065   collect(elem);
00066 };
00067 
00068 void _forward_collect(const LangElems * elem)
00069 {
00070   collect(elem);
00071 };
00072 
00073 void _forward_collect(const NamedSubExpsLangElem * elem)
00074 {
00075   collect(elem);
00076 };
00077 
00078 void _forward_collect(const StateLangElem * elem)
00079 {
00080   collect(elem);
00081 };
00082 
00083 protected:
00084 virtual void collect_DB(const LangElem * elem);
00085 virtual void collect_DB(const LangElems * elem);
00086 #line 49 "langelemsprinter.h"
00087 // doublecpp: end, DO NOT MODIFY
00088 
00089 };
00090 
00091 }
00092 
00093 #endif