#include <stream.hpp>
Inheritance diagram for CCompressionStream:


Definition at line 103 of file stream.hpp.
Public Types | |
| typedef int | TOwnership |
| Bitwise OR of EOwnership. | |
| enum | EDirection { eRead, eWrite, eReadWrite } |
| Stream processing direction. More... | |
| enum | EOwnership { fOwnStream = (1<<1), fOwnReader = (1<<2), fOwnWriter = (1<<3), fOwnProcessor = fOwnReader + fOwnWriter, fOwnAll = fOwnStream + fOwnProcessor } |
| Which of the objects (passed in the constructor) should be deleted on this object's destruction. More... | |
Public Member Functions | |
| CCompressionStream (CNcbiIos &stream, CCompressionStreamProcessor *read_sp, CCompressionStreamProcessor *write_sp, TOwnership ownership=0) | |
| Constructor. | |
| virtual | ~CCompressionStream (void) |
| Destructor. | |
| virtual void | Finalize (CCompressionStream::EDirection dir=CCompressionStream::eReadWrite) |
| Finalize stream's compression/decompression process for read/write. | |
Protected Member Functions | |
| CCompressionProcessor::EStatus | x_GetStatus (CCompressionStream::EDirection dir) |
| Get status of last compression/decompression stream operation. | |
| bool | x_GetError (CCompressionStream::EDirection dir, int &status, string &description) |
| Get error code and description of last compressor/decompressor stream operation. | |
| unsigned long | x_GetProcessedSize (CCompressionStream::EDirection dir) |
| Return number of processed bytes. | |
| unsigned long | x_GetOutputSize (CCompressionStream::EDirection dir) |
| Return number of output bytes. | |
Protected Attributes | |
| CNcbiIos * | m_Stream |
| Underlying stream. | |
| CCompressionStreambuf * | m_StreamBuf |
| Stream buffer. | |
| CCompressionStreamProcessor * | m_Reader |
| Read processor. | |
| CCompressionStreamProcessor * | m_Writer |
| Write processor. | |
| TOwnership | m_Ownership |
| Bitwise OR of EOwnership. | |
|
|
Bitwise OR of EOwnership.
Definition at line 124 of file stream.hpp. |
|
|
Stream processing direction.
Definition at line 107 of file stream.hpp. |
|
|
Which of the objects (passed in the constructor) should be deleted on this object's destruction. NOTE: if the reader and writer are in fact one object, it will not be deleted twice.
Definition at line 117 of file stream.hpp. |
|
||||||||||||||||||||
|
Constructor. If read/write stream processor is 0 (NULL), that read/write operations on this stream will be unsuccessful. Definition at line 95 of file stream.cpp. References auto_ptr< X >::get(), init(), m_StreamBuf, and auto_ptr< X >::release(). |
|
|
Destructor.
Definition at line 113 of file stream.cpp. References fOwnReader, fOwnStream, fOwnWriter, m_Ownership, m_Reader, m_Stream, m_StreamBuf, and m_Writer. |
|
|
Finalize stream's compression/decompression process for read/write. This function just calls a streambuf Finalize(). Definition at line 147 of file stream.cpp. References CCompressionStreambuf::Finalize(), and m_StreamBuf. Referenced by CZipCompressionFile::Close(). |
|
||||||||||||||||
|
Get error code and description of last compressor/decompressor stream operation. Return TRUE if information obtained successfully. Definition at line 166 of file stream.cpp. References eRead, CCompression::GetErrorCode(), CCompression::GetErrorDescription(), CCompressionStreamProcessor::m_Processor, m_Reader, and m_Writer. Referenced by CCompressionIOStream::GetError(), CCompressionOStream::GetError(), and CCompressionIStream::GetError(). |
|
|
Return number of output bytes.
Definition at line 199 of file stream.cpp. References eRead, CCompressionProcessor::GetOutputSize(), CCompressionStreamProcessor::m_Processor, m_Reader, and m_Writer. Referenced by CCompressionIOStream::GetOutputSize(), CCompressionOStream::GetOutputSize(), and CCompressionIStream::GetOutputSize(). |
|
|
Return number of processed bytes.
Definition at line 188 of file stream.cpp. References eRead, CCompressionProcessor::GetProcessedSize(), CCompressionStreamProcessor::m_Processor, m_Reader, and m_Writer. Referenced by CCompressionIOStream::GetProcessedSize(), CCompressionOStream::GetProcessedSize(), and CCompressionIStream::GetProcessedSize(). |
|
|
Get status of last compression/decompression stream operation.
Definition at line 156 of file stream.cpp. References eRead, CCompressionProcessor::eStatus_Unknown, CCompressionStreamProcessor::m_LastStatus, m_Reader, and m_Writer. Referenced by CCompressionIOStream::GetStatus(), CCompressionOStream::GetStatus(), and CCompressionIStream::GetStatus(). |
|
|
Bitwise OR of EOwnership.
Definition at line 159 of file stream.hpp. Referenced by ~CCompressionStream(). |
|
|
Read processor.
Definition at line 157 of file stream.hpp. Referenced by x_GetError(), x_GetOutputSize(), x_GetProcessedSize(), x_GetStatus(), and ~CCompressionStream(). |
|
|
Underlying stream.
Definition at line 155 of file stream.hpp. Referenced by ~CCompressionStream(). |
|
|
Stream buffer.
Definition at line 156 of file stream.hpp. Referenced by CCompressionStream(), Finalize(), and ~CCompressionStream(). |
|
|
Write processor.
Definition at line 158 of file stream.hpp. Referenced by x_GetError(), x_GetOutputSize(), x_GetProcessedSize(), x_GetStatus(), and ~CCompressionStream(). |
1.4.6
Modified on Wed Dec 09 08:19:02 2009 by modify_doxy.py rev. 173732