#include <mstream.h>
Inheritance diagram for Stream:
Public Types | |
enum | Encoding |
Public Methods | |
Stream (IODevice &dev) | |
Stream (IODevice *dev) | |
Stream (String &buffer) | |
Stream (FILE *strm) | |
Stream (Stream &orig) | |
virtual | ~Stream () |
void | setDevice (IODevice *dev) |
virtual void | copy (const Stream &other) |
Protected Attributes | |
bool | mOwnDevice |
int | mFormatMode |
Encoding | mEncoding |
ulong | mFlags |
All streams always have an associated device, the type of which can vary.
Definition at line 51 of file mstream.h.
|
Defines the character encoding of the stream.
|
|
Constructor from a reference to a device. Because the device was given with a reference, the stream object does not take the ownership of the device object and therefore does not destroy it along with itself. Definition at line 71 of file mstream.cc. References mFormatMode, and mOwnDevice. |
|
Constructor from a pointer to a device. Because the device was given with a pointer, the stream object takes the ownership of the device object and destroys it along with itself. Definition at line 82 of file mstream.cc. References mFormatMode, and mOwnDevice. |
|
Shorthand constructor for a buffer device. The IODevice object is handled internally. The stream object keeps the ownership of the device object and destroys it along with itself. Definition at line 94 of file mstream.cc. References mFormatMode, and mOwnDevice. |
|
Shorthand constructor for a file device. The IODevice object is handled internally. The stream object keeps the ownership of the device object and destroys it along with itself. Definition at line 106 of file mstream.cc. References mFormatMode, and mOwnDevice. |
|
Copy constructor.
Definition at line 115 of file mstream.cc. References IODevice::addStream(), mEncoding, mFlags, mFormatMode, mOwnDevice, and mpDevice. |
|
Destructor for the stream. The associated device is destructed along with the stream, unless passed with a reference. Definition at line 132 of file mstream.cc. |
|
Copy operator. Warning: Does not take ownership of the device to which the stream is attached. Definition at line 173 of file mstream.cc. References mEncoding, mFlags, mFormatMode, mOwnDevice, and mpDevice. Referenced by OStream::copy(). |
|
Sets the device for the stream.
Definition at line 151 of file mstream.cc. References mOwnDevice. |
|
The text encoding mode.
|
|
User-defined stream flags.
|
|
Formatting mode.
|
|
Does the object own the IODevice?
Definition at line 85 of file mstream.h. Referenced by copy(), setDevice(), and Stream(). |