1 #ifndef MSP_DATAFILE_BINARYWRITER_H_
2 #define MSP_DATAFILE_BINARYWRITER_H_
5 #include "binarydict.h"
7 #include "writermode.h"
13 Writes data in binary format.
15 class BinaryWriter: public WriterMode
18 typedef std::map<DictEntry, unsigned> Dictionary;
19 typedef std::map<std::string, unsigned> StringMap;
27 BinaryWriter(IO::Base &o);
29 virtual void write(const Statement &st);
31 void write_(const Statement &st);
32 void collect_keywords(const Statement &st);
33 void write_int(IntType::Store n);
34 void write_string(const StringType::Store &s);
35 void write_float(FloatType::Store f);
36 void write_symbol(const SymbolType::Store &s);
39 } // namespace DataFile