4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Lars Gullik Bjønnes
9 * Full author contact details are available in file CREDITS.
12 #ifndef LYXLEX_PIMPL_H
13 #define LYXLEX_PIMPL_H
17 #ifdef USE_COMPRESSION
18 # include "support/gzstream.h"
21 #include <boost/utility.hpp>
28 class LyXLex::Pimpl : boost::noncopyable {
31 Pimpl(keyword_item * tab, int num);
33 std::string const getString() const;
35 void printError(std::string const & message) const;
37 void printTable(std::ostream & os);
39 void pushTable(keyword_item * tab, int num);
43 bool setFile(std::string const & filename);
45 void setStream(std::istream & i);
47 void setCommentChar(char c);
49 bool next(bool esc = false);
51 int search_kw(char const * const tag) const;
59 void pushToken(std::string const &);
60 /// fb_ is only used to open files, the stream is accessed through is.
63 #ifdef USE_COMPRESSION
64 /// gz_ is only used to open files, the stream is accessed through is.
68 /// the stream that we use.
77 std::vector<char> buff;
94 : table_elem(0), table_siz(0) {}
96 pushed_table(keyword_item * ki, int siz)
97 : table_elem(ki), table_siz(siz) {}
99 keyword_item * table_elem;
104 std::stack<pushed_table> pushed;