strigi/src/streams
Strigi::StreamBaseBase Class Reference
The base of all Streams. More...
#include <streambase.h>

Public Member Functions | |
| StreamBaseBase () | |
| virtual | ~StreamBaseBase () |
| const char * | error () const |
| int64_t | position () const |
| int64_t | size () const |
| StreamStatus | status () const |
Protected Attributes | |
| std::string | m_error |
| int64_t | m_position |
| int64_t | m_size |
| StreamStatus | m_status |
Detailed Description
The base of all Streams.
Do not inherit directly from this class, but from (an instance of) StreamBase
This class contains all the non-virtual StreamBase methods that don't depend on a specific Stream type
Developer comment: This is needed because of win32 compilation. When we want to access a function outside a lib, we have to export them, but we can't export the template class because this would be somewhat stupid / does not work by design :) Because of this I've introduced this StreamBaseBase class
Definition at line 52 of file streambase.h.
Constructor & Destructor Documentation
| Strigi::StreamBaseBase::StreamBaseBase | ( | ) | [inline] |
Constructor: initialises everything to sane defaults.
Definition at line 69 of file streambase.h.
| virtual Strigi::StreamBaseBase::~StreamBaseBase | ( | ) | [inline, virtual] |
Destructor.
Definition at line 73 of file streambase.h.
Member Function Documentation
| const char* Strigi::StreamBaseBase::error | ( | ) | const [inline] |
Return a string representation of the last error.
If no error has occurred, an empty string is returned.
Definition at line 78 of file streambase.h.
| int64_t Strigi::StreamBaseBase::position | ( | ) | const [inline] |
Get the current position in the stream.
The value obtained from this function can be used to reset the stream.
Definition at line 87 of file streambase.h.
| int64_t Strigi::StreamBaseBase::size | ( | ) | const [inline] |
Return the size of the stream.
The size of the stream is always known if the end of the stream has been reached. In all other cases, this may return -1 to indicate the size of the stream is unknown.
- Returns:
- the size of the stream, if it is known, or -1 if the size of the stream is unknown
Definition at line 98 of file streambase.h.
| StreamStatus Strigi::StreamBaseBase::status | ( | ) | const [inline] |
Return the status of the stream.
Definition at line 82 of file streambase.h.
Member Data Documentation
std::string Strigi::StreamBaseBase::m_error [protected] |
String representation of the last error, or an empty string otherwise.
Definition at line 62 of file streambase.h.
int64_t Strigi::StreamBaseBase::m_position [protected] |
The position of the stream.
Definition at line 57 of file streambase.h.
int64_t Strigi::StreamBaseBase::m_size [protected] |
The size of the stream (-1 if unknown).
Definition at line 55 of file streambase.h.
StreamStatus Strigi::StreamBaseBase::m_status [protected] |
The status of the stream - see StreamStatus.
Definition at line 64 of file streambase.h.
The documentation for this class was generated from the following file:
KDE 4.4 API Reference