/**
@class wxDataOutputStream
- @wxheader{datstrm.h}
This class provides functions that write binary data types in a portable
way. Data can be written in either big-endian or little-endian format,
{
public:
/**
- Constructs a datastream object from an output stream. Only write
- methods will be available.
+ Constructs a datastream object from an output stream.
+ Only write methods will be available.
- @param stream
- The output stream.
- */
- wxDataOutputStream(wxOutputStream& stream);
- /**
- Constructs a datastream object from an output stream. Only write
- methods will be available. This constructor is only available in
- Unicode builds of wxWidgets.
+ Note that the @a conv parameter is only available in Unicode builds of wxWidgets.
@param stream
The output stream.
instance! It is recommended to use the default value (UTF-8).
*/
wxDataOutputStream(wxOutputStream& stream,
- const wxMBConv& conv = wxConvAuto());
+ const wxMBConv& conv = wxConvUTF8);
/**
Destroys the wxDataOutputStream object.
order.
*/
void BigEndianOrdered(bool be_order);
+
+ /**
+ Returns the current text conversion class used for
+ writing strings.
+ */
+ wxMBConv *GetConv() const;
+ /**
+ Sets the text conversion class used for writing strings.
+ */
+ void SetConv( const wxMBConv &conv );
+
/**
Writes the single byte @a i8 to the stream.
*/
/**
@class wxDataInputStream
- @wxheader{datstrm.h}
This class provides functions that read binary data types in a portable
way. Data can be read in either big-endian or little-endian format,
{
public:
/**
- Constructs a datastream object from an input stream. Only read methods
- will be available.
+ Constructs a datastream object from an input stream.
+ Only read methods will be available.
- @param stream
- The input stream.
- */
- wxDataInputStream(wxInputStream& stream);
- /**
- Constructs a datastream object from an input stream. Only read methods
- will be available. This constructor is only available in Unicode builds
- of wxWidgets.
+ Note that the @a conv parameter is only available in Unicode builds of wxWidgets.
@param stream
The input stream.
instance!
*/
wxDataInputStream(wxInputStream& stream,
- const wxMBConv& conv = wxConvAuto());
+ const wxMBConv& conv = wxConvUTF8 );
/**
Destroys the wxDataInputStream object.
*/
void BigEndianOrdered(bool be_order);
+
+ /**
+ Returns the current text conversion class used for
+ reading strings.
+ */
+ wxMBConv *GetConv() const;
+
/**
Reads a single byte from the stream.
*/
@see wxDataOutputStream::WriteString()
*/
wxString ReadString();
+
+ /**
+ Sets the text conversion class used for reading strings.
+ */
+ void SetConv( const wxMBConv &conv );
};