ds9parser.h

Go to the documentation of this file.
00001 #ifndef DISPLAY_DS9_PARSER_H_
00002 #define DISPLAY_DS9_PARSER_H_
00003 
00004 #include <string>
00005 #include <vector>
00006 #include <display/ds9/ds9lex.h>
00007 
00008 namespace casa {
00009         namespace viewer {
00010 
00011                 class ds9parser {
00012                 public:
00013                         ds9parser( );
00014 
00016                         bool trace_scanning;
00017 
00019                         bool trace_parsing;
00020 
00022                         std::string streamname;
00023 
00024                         // input stream, stream name for error messages, return true if successfully parsed
00025                         bool parse_stream(ds9context &base, std::istream& in, const std::string& sname = "stream input");
00026 
00027                         bool parse_string(ds9context &base, const std::string& input, const std::string& sname = "string stream");
00028 
00029                         bool parse_file(ds9context &base, const std::string& filename);
00030 
00031                         // To demonstrate pure handling of parse errors, instead of
00032                         // simply dumping them on the standard error output, we will pass
00033                         // them to the driver using the following two member functions.
00034 
00037                         void error(const class location& l, const std::string& m);
00038 
00041                         void error(const std::string& m);
00042                         ds9lex* lexer;
00043 
00044                 };
00045 
00046         }
00047 }
00048 
00049 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 31 Aug 2016 for casa by  doxygen 1.6.1