NwaParser.hpp

Go to the documentation of this file.
00001 #ifndef NWA_PARSER_HPP
00002 #define NWA_PARSER_HPP
00003 
00004 #include <iosfwd>
00005 #include <string>
00006 #include "Nwa.hpp"
00007 
00008 namespace opennwa {
00009 
00010     /// Reads a single NWA from 'is'. If 'name' is nonnull and the
00011     /// stream specifies a name, store the NWA's name at the location
00012     /// pointed to by 'name'.
00013     extern NwaRefPtr read_nwa(std::istream & is, std::string * name = NULL);
00014 
00015     /// A collection of named NWAs.
00016     ///
00017     typedef std::map<std::string, NwaRefPtr> ProcedureMap;
00018 
00019     /// Reads a stream full of NWA descriptions, returning the set of
00020     /// named NWAs. (The NWAs in the stream better all have unique
00021     /// names, or only the last one of each name will be returned. No
00022     /// attempt is made to verify this fact.)
00023     extern ProcedureMap read_nwa_proc_set(std::istream & is);
00024 
00025     /// Run NWA Parser unit tests
00026     ///
00027     extern void parser_test_all();
00028 
00029 }
00030 
00031 
00032 // Yo, Emacs!
00033 // Local Variables:
00034 //   c-file-style: "ellemtel"
00035 //   c-basic-offset: 2
00036 // End:
00037 
00038 #endif