Source-highlight Library
|
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 class LangElemsPrinter 00027 { 00028 typedef std::set<std::string> SetOfElements; 00029 SetOfElements setOfElements; 00030 00031 public: 00032 LangElemsPrinter(); 00033 00034 virtual ~LangElemsPrinter(); 00035 00042 void print(const LangElems *elems, std::ostream &os); 00043 00044 protected: 00045 branches collect 00046 void (const StateLangElem *elem); 00047 void (const LangElem *elem); 00048 void (const LangElems *elem); 00049 void (const NamedSubExpsLangElem *elem); 00050 endbranches 00051 }; 00052 00053 } 00054 00055 #endif