17 #ifndef CPP_MATE_FILE_WRITER_HPP
18 #define CPP_MATE_FILE_WRITER_HPP
20 #include <CppMate/BinarySink.hpp>
56 static std::shared_ptr<FileWriter>
create(
const std::string& filename,
Mode mode);
Represents closable extension of the BinarySink interface.
Definition: BinarySink.hpp:62
Represents file writer with platform-dependent implementation.
Definition: FileWriter.hpp:31
Mode
The creation mode.
Definition: FileWriter.hpp:37
@ New
Creates new file and throws exception if it already exists.
@ Append
Appends data to the end of the existing file.
@ Overwrite
Overwrites file if it already exists.
virtual std::string getFilename() const =0
Returns name of file.
static std::shared_ptr< FileWriter > create(const std::string &filename, Mode mode)
Creates new file writer for specified filename.
Definition: BinaryData.hpp:28