Go to the documentation of this file.
9 #ifndef CFileOutputStream_H
10 #define CFileOutputStream_H
43 const std::string &fileName,
56 bool open(
const std::string &fileName,
bool append =
false );
65 bool is_open() {
return fileOpenCorrectly(); }
bool is_open()
Returns true if the file was open without errors.
size_t Write(const void *Buffer, size_t Count) MRPT_OVERRIDE
Introduces a pure virtual method responsible for writing to the stream.
bool open(const std::string &fileName, bool append=false)
Open the given file for write.
std::ofstream m_of
The actual output file stream.
bool fileOpenCorrectly()
Returns true if the file was open without errors.
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
size_t Read(void *Buffer, size_t Count) MRPT_OVERRIDE
Introduces a pure virtual method responsible for reading from the stream.
CFileOutputStream(const std::string &fileName, bool append=false)
Constructor.
This base class is used to provide a unified interface to files,memory buffers,..Please see the deriv...
The base class of classes that cannot be copied: compile-time errors will be issued on any copy opera...
virtual ~CFileOutputStream()
Destructor.
CFileOutputStream()
Default constructor.
TSeekOrigin
Used in CStream::Seek.
uint64_t Seek(uint64_t Offset, CStream::TSeekOrigin Origin=sFromBeginning) MRPT_OVERRIDE
Introduces a pure virtual method for moving to a specified position in the streamed resource.
#define MRPT_OVERRIDE
C++11 "override" for virtuals:
uint64_t getTotalBytesCount() MRPT_OVERRIDE
Method for getting the total number of bytes writen to buffer.
void close()
Close the stream.
This CStream derived class allow using a file as a write-only, binary stream.
Page generated by Doxygen 1.8.20 for MRPT 1.4.0 SVN: at Thu Aug 27 02:40:23 UTC 2020 | | |