#include <TempFileStream.hpp>
Definition at line 103 of file TempFileStream.hpp.
◆ EKeepFileFlag
◆ TempFileBuffer() [1/3]
Create a new TempFileBuffer object.
- Parameters
-
| bufSize | The size of the buffer used by this stream. |
| keepflg | If E_KEEP_FILE is specified the temporary file used by this object will not be deleted on destruction. The caller is responsible for calling releaseFileAnReset to get the file name of the underlying temp file. If releaseFileAndReset is never called this object will attempt to delete the temp file on destruction. |
Definition at line 86 of file TempFileStream.cpp.
References initGetBuffer(), and initPutBuffer().
◆ TempFileBuffer() [2/3]
Create a new TempFileBuffer object.
- Parameters
-
| dir | The directory that will contain the temp file used by this object. |
| bufSize | The size of the buffer used by this stream. |
| keepflg | If E_KEEP_FILE is specified the temporary file used by this object will not be deleted on destruction. The caller is responsible for calling releaseFileAndReset to get the file name of the underlying temp file. If releaseFileAndReset is never called this object will attempt to delete the temp file on destruction. |
Definition at line 102 of file TempFileStream.cpp.
References m_buffer.
◆ ~TempFileBuffer()
| BLOCXX_NAMESPACE::TempFileBuffer::~TempFileBuffer |
( |
| ) |
|
◆ TempFileBuffer() [3/3]
| BLOCXX_NAMESPACE::TempFileBuffer::TempFileBuffer |
( |
const TempFileBuffer & |
arg | ) |
|
|
private |
◆ buffer_from_device()
| int BLOCXX_NAMESPACE::TempFileBuffer::buffer_from_device |
( |
char * |
c, |
|
|
int |
n |
|
) |
| |
|
protected |
◆ buffer_in()
| int BLOCXX_NAMESPACE::TempFileBuffer::buffer_in |
( |
| ) |
|
|
private |
◆ buffer_out()
| int BLOCXX_NAMESPACE::TempFileBuffer::buffer_out |
( |
| ) |
|
|
private |
◆ buffer_to_device()
| int BLOCXX_NAMESPACE::TempFileBuffer::buffer_to_device |
( |
const char * |
c, |
|
|
int |
n |
|
) |
| |
|
protected |
◆ getSize()
| std::streamsize BLOCXX_NAMESPACE::TempFileBuffer::getSize |
( |
| ) |
|
◆ initBuffers()
| void BLOCXX_NAMESPACE::TempFileBuffer::initBuffers |
( |
| ) |
|
|
protected |
◆ initGetBuffer()
| void BLOCXX_NAMESPACE::TempFileBuffer::initGetBuffer |
( |
| ) |
|
|
protected |
◆ initPutBuffer()
| void BLOCXX_NAMESPACE::TempFileBuffer::initPutBuffer |
( |
| ) |
|
|
protected |
◆ operator=()
◆ overflow()
| int BLOCXX_NAMESPACE::TempFileBuffer::overflow |
( |
int |
c | ) |
|
|
protectedvirtual |
◆ releaseFileAndReset()
| String BLOCXX_NAMESPACE::TempFileBuffer::releaseFileAndReset |
( |
| ) |
|
releaseFileAndReset is like the reset method except it ensures all data has been flused to the underlying file and returned name of the file if the caller requested that it not be deleted.
- Returns
- The name of the underlying temp file if the caller requested that it not be deleted on close.
Definition at line 381 of file TempFileStream.cpp.
References BLOCXX_NAMESPACE::TempFileStream::m_buffer.
◆ reset()
| void BLOCXX_NAMESPACE::TempFileBuffer::reset |
( |
| ) |
|
reset puts this stream object back into its initialized state.
If a tempfile exists, it is deleted. It is not recomended to use this method if you requested the underlying file not be deleted. You should should call releaseFileAndReset under those conditions. This will give you the name of the underlying file that you can delete if you desire.
Definition at line 366 of file TempFileStream.cpp.
◆ rewind()
| void BLOCXX_NAMESPACE::TempFileBuffer::rewind |
( |
| ) |
|
◆ underflow()
| int BLOCXX_NAMESPACE::TempFileBuffer::underflow |
( |
| ) |
|
|
protected |
◆ usingTempFile()
| bool BLOCXX_NAMESPACE::TempFileBuffer::usingTempFile |
( |
| ) |
const |
- Returns
- true if the temp is being used. This could return false if none of the buffered data has been written to disk yet. If this method returns false, it doesn't necessarily mean that a temp file won't be used when the data is flushed.
Definition at line 392 of file TempFileStream.cpp.
◆ xsputn()
| std::streamsize BLOCXX_NAMESPACE::TempFileBuffer::xsputn |
( |
const char * |
s, |
|
|
std::streamsize |
n |
|
) |
| |
|
protected |
◆ m_buffer
| char* BLOCXX_NAMESPACE::TempFileBuffer::m_buffer |
|
private |
◆ m_bufSize
| size_t BLOCXX_NAMESPACE::TempFileBuffer::m_bufSize |
|
private |
◆ m_dir
| String BLOCXX_NAMESPACE::TempFileBuffer::m_dir |
|
private |
◆ m_filePath
| String BLOCXX_NAMESPACE::TempFileBuffer::m_filePath |
|
private |
◆ m_isEOF
| bool BLOCXX_NAMESPACE::TempFileBuffer::m_isEOF |
|
private |
◆ m_keepFlag
◆ m_readPos
| std::streamsize BLOCXX_NAMESPACE::TempFileBuffer::m_readPos |
|
private |
◆ m_tempFile
| File BLOCXX_NAMESPACE::TempFileBuffer::m_tempFile |
|
private |
◆ m_writePos
| std::streamsize BLOCXX_NAMESPACE::TempFileBuffer::m_writePos |
|
private |
The documentation for this class was generated from the following files: