3#include <Foundation/IO/FileSystem/FileWriter.h>
4#include <Foundation/IO/MemoryStream.h>
19 void SetOutput(
plStringView sFileToWriteTo,
bool bOnlyWriteIfDifferent =
false);
21 virtual plResult WriteBytes(
const void* pWriteBuffer, plUInt64 uiBytesToWrite)
override;
25 plResult Close(
bool* out_pWasWrittenTo =
nullptr);
32 bool m_bOnlyWriteIfDifferent =
false;
33 bool m_bAlreadyClosed =
false;
The default implementation for memory stream storage.
Definition MemoryStream.h:161
A file writer that caches all written data and only opens and writes to the output file when everythi...
Definition DeferredFileWriter.h:9
~plDeferredFileWriter()
Upon destruction the file is closed and thus written, unless Discard was called before.
Definition DeferredFileWriter.h:16
A writer which can access a memory stream.
Definition MemoryStream.h:313
Interface for binary out (write) streams.
Definition Stream.h:107
virtual plResult WriteBytes(const void *pWriteBuffer, plUInt64 uiBytesToWrite)=0
Writes a raw number of bytes from the buffer, this is the only method which has to be implemented to ...
plStringView represent a read-only sub-string of a larger string, as it can store a dedicated string ...
Definition StringView.h:34
Default enum for returning failure or success, instead of using a bool.
Definition Types.h:54