+wxOutputStream& WXDLLEXPORT wxEndL(wxOutputStream& o_stream);
+
+// Disable warnings such as
+// 'wxFilterStream' : inherits 'wxFilterInputStream::Peek' via dominance
+
+#ifdef _MSC_VER
+#pragma warning(disable:4250)
+#endif
+
+// ---------------------------------------------------------------------------
+// Stream buffer
+// ---------------------------------------------------------------------------
+
+class WXDLLEXPORT wxStreamBuffer {
+ public:
+ wxStreamBuffer(wxInputStream& stream);
+ wxStreamBuffer(wxOutputStream& stream);
+ ~wxStreamBuffer();
+
+ void Read(void *buffer, size_t size);
+ void Write(const void *buffer, size_t size);
+ void WriteBack(char c);
+
+ void SetBufferIO(char *buffer_start, char *buffer_end);
+ void SetBufferIO(size_t bufsize);
+ void ResetBuffer();
+
+ void SetBufferPosition(char *buffer_position)
+ { m_buffer_pos = buffer_position; }
+ void SetIntPosition(size_t pos)
+ { m_buffer_pos = m_buffer_start + pos; }
+ char *GetBufferPosition() const { return m_buffer_pos; }
+ size_t GetIntPosition() const { return m_buffer_pos - m_buffer_start; }
+
+ char *GetBufferStart() const { return m_buffer_start; }
+ char *GetBufferEnd() const { return m_buffer_end; }
+ size_t GetBufferSize() const { return m_buffer_size; }
+ size_t GetLastAccess() const { return m_buffer_end - m_buffer_start; }
+
+ protected:
+ char *m_buffer_start, *m_buffer_end, *m_buffer_pos;
+ size_t m_buffer_size;
+
+ wxInputStream *m_istream;
+ wxOutputStream *m_ostream;
+};
+
+// ---------------------------------------------------------------------------
+// wxStream: base classes
+// ---------------------------------------------------------------------------
+
+class WXDLLEXPORT wxInputStream {