#include <WPXStreamImplementation.h>
Public Member Functions | |
WPXStringStream (const unsigned char *data, const unsigned int dataSize) | |
~WPXStringStream () | |
const unsigned char * | read (unsigned long numBytes, unsigned long &numBytesRead) |
Tries to read a given number of bytes starting from the current position inside the input stream. | |
long | tell () |
Returns the actual position inside the input stream. | |
int | seek (long offset, WPX_SEEK_TYPE seekType) |
Moves to the next location inside the input stream. | |
bool | atEOS () |
Determines whether the current position is at the end of the stream. | |
bool | isOLEStream () |
Analyses the content of the input stream to see whether it is an OLE2 storage. | |
WPXInputStream * | getDocumentOLEStream (const char *name) |
Extracts a PerfectOffice_MAIN stream from an OLE2 storage. | |
Private Member Functions | |
WPXStringStream (const WPXStringStream &) | |
WPXStringStream & | operator= (const WPXStringStream &) |
Private Attributes | |
WPXStringStreamPrivate * | d |
WPXStringStream::WPXStringStream | ( | const unsigned char * | data, |
const unsigned int | dataSize | ||
) |
Referenced by getDocumentOLEStream().
WPXStringStream::~WPXStringStream | ( | ) |
WPXStringStream::WPXStringStream | ( | const WPXStringStream & | ) | [private] |
bool WPXStringStream::atEOS | ( | ) | [virtual] |
Determines whether the current position is at the end of the stream.
Implements WPXInputStream.
Referenced by read().
WPXInputStream * WPXStringStream::getDocumentOLEStream | ( | const char * | name ) | [virtual] |
Extracts a PerfectOffice_MAIN
stream from an OLE2 storage.
PerfectOffice_MAIN
stream if it exists. PerfectOffice_MAIN
stream does not exist inside the OLE2 storage or if the input stream is not an OLE2 storage. Implements WPXInputStream.
bool WPXStringStream::isOLEStream | ( | ) | [virtual] |
Analyses the content of the input stream to see whether it is an OLE2 storage.
Implements WPXInputStream.
WPXStringStream& WPXStringStream::operator= | ( | const WPXStringStream & | ) | [private] |
const unsigned char * WPXStringStream::read | ( | unsigned long | numBytes, |
unsigned long & | numBytesRead | ||
) | [virtual] |
Tries to read a given number of bytes starting from the current position inside the input stream.
numBytes | Number of bytes desired to be read. |
numBytesRead | Number of bytes that were possible to be read. |
Implements WPXInputStream.
int WPXStringStream::seek | ( | long | offset, |
WPX_SEEK_TYPE | seekType | ||
) | [virtual] |
Moves to the next location inside the input stream.
offset | The offset of the location inside the input stream to move to. It is relative either to the current position or to the beginning of the input stream depending on the value of the seekType parameter. |
seekType | Determines whether the offset is relative to the beginning of the input stream (WPX_SEEK_SET ) or to the current position (WPX_SEEK_CUR ). |
offset
is beyond the end of the input stream or before its beginning). Implements WPXInputStream.
Referenced by isOLEStream().
long WPXStringStream::tell | ( | ) | [virtual] |
Returns the actual position inside the input stream.
Implements WPXInputStream.
Referenced by seek().
WPXStringStreamPrivate* WPXStringStream::d [private] |
Referenced by atEOS(), getDocumentOLEStream(), isOLEStream(), read(), seek(), tell(), WPXStringStream(), and ~WPXStringStream().