diff options
author | John Wiegley <johnw@newartisans.com> | 2008-04-13 03:35:00 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2008-04-13 03:35:00 -0400 |
commit | 42f43b7686038e4cbca16d8d2118b139544e6de3 (patch) | |
tree | 52c5473401c57282242d66b8dd75f4c07bf41d07 /parser.h | |
parent | c7b4370ff9c8ab5c96f15b1e712e6db6bdab6324 (diff) | |
download | fork-ledger-42f43b7686038e4cbca16d8d2118b139544e6de3.tar.gz fork-ledger-42f43b7686038e4cbca16d8d2118b139544e6de3.tar.bz2 fork-ledger-42f43b7686038e4cbca16d8d2118b139544e6de3.zip |
Check in all changes made so far toward 3.0.
Diffstat (limited to 'parser.h')
-rw-r--r-- | parser.h | 32 |
1 files changed, 3 insertions, 29 deletions
@@ -1,16 +1,15 @@ #ifndef _PARSER_H #define _PARSER_H -#include <iostream> -#include <string> - #include "error.h" +#include <string> +#include <istream> + namespace ledger { class account_t; class journal_t; -class config_t; class parser_t { @@ -20,36 +19,11 @@ class parser_t virtual bool test(std::istream& in) const = 0; virtual unsigned int parse(std::istream& in, - config_t& config, journal_t * journal, account_t * master = NULL, const std::string * original_file = NULL) = 0; }; -bool register_parser(parser_t * parser); -bool unregister_parser(parser_t * parser); - -unsigned int parse_journal(std::istream& in, - config_t& config, - journal_t * journal, - account_t * master = NULL, - const std::string * original_file = NULL); - -unsigned int parse_journal_file(const std::string& path, - config_t& config, - journal_t * journal, - account_t * master = NULL, - const std::string * original_file = NULL); - -unsigned int parse_ledger_data(config_t& config, - journal_t * journal, - parser_t * cache_parser = NULL, - parser_t * xml_parser = NULL, - parser_t * stdin_parser = NULL); - -void initialize_parser_support(); -void shutdown_parser_support(); - class parse_error : public error { public: parse_error(const std::string& reason, error_context * ctxt = NULL) throw() |