Unfortunately, threads have only very minimal and rudimentary support.
, , , , , , . , .
, , , , . ( , .) :
class parse_buffer {
friend class parse_state;
public:
typedef std::string::size_type index_type;
parse_buffer(std::istream& str);
index_type get_current_index() const;
void set_current_index(index_type) const;
std::string get_next_string(bool skip_ws = true) const;
char get_next_char(bool skip_ws = true);
char peek_next_char(bool skip_ws = true);
std::string get_error_string() const;
index_type get_error_index() const;
void set_error_index(index_type);
bool eof() const;
};
class parse_state {
public:
parse_state(parse_buffer&);
~parse_state();
void commit();
void rollback();
};
. , . , , , , , , , , .
, , , . . parse_state , , - , ( get_error_string()).
, , . OTOH, , - , XPath, DOM, 3D-. XPath , . :)