17 #ifndef CARTOGRAPHER_IO_FILE_WRITER_H_ 18 #define CARTOGRAPHER_IO_FILE_WRITER_H_ 41 virtual bool WriteHeader(
const char* data,
size_t len) = 0;
43 virtual bool Write(
const char* data,
size_t len) = 0;
44 virtual bool Close() = 0;
55 bool Write(
const char* data,
size_t len)
override;
56 bool WriteHeader(
const char* data,
size_t len)
override;
57 bool Close()
override;
66 std::function<std::unique_ptr<FileWriter>(
const std::string& filename)>;
71 #endif // CARTOGRAPHER_IO_FILE_WRITER_H_ std::function< std::unique_ptr< FileWriter >(const std::string &filename)> FileWriterFactory
FileWriter & operator=(const FileWriter &)=delete
virtual std::string GetFilename()=0
virtual bool WriteHeader(const char *data, size_t len)=0
const std::string filename_
virtual bool Write(const char *data, size_t len)=0