1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Memory stream classes
4 // Author: Guilhem Lavaux
8 // Copyright: (c) Guilhem Lavaux
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11 #ifndef _WX_WXZSTREAM_H__
12 #define _WX_WXZSTREAM_H__
14 #if defined(__GNUG__) && !defined(__APPLE__)
15 #pragma interface "zstream.h"
20 #if wxUSE_ZLIB && wxUSE_STREAMS
22 #include "wx/stream.h"
24 class WXDLLEXPORT_BASE wxZlibInputStream
: public wxFilterInputStream
{
26 wxZlibInputStream(wxInputStream
& stream
);
27 virtual ~wxZlibInputStream();
30 size_t OnSysRead(void *buffer
, size_t size
);
34 unsigned char *m_z_buffer
;
35 struct z_stream_s
*m_inflate
;
37 DECLARE_NO_COPY_CLASS(wxZlibInputStream
)
40 class WXDLLEXPORT_BASE wxZlibOutputStream
: public wxFilterOutputStream
{
42 wxZlibOutputStream(wxOutputStream
& stream
, int level
= -1);
43 virtual ~wxZlibOutputStream();
48 size_t OnSysWrite(const void *buffer
, size_t size
);
52 unsigned char *m_z_buffer
;
53 struct z_stream_s
*m_deflate
;
55 DECLARE_NO_COPY_CLASS(wxZlibOutputStream
)
59 // wxUSE_ZLIB && wxUSE_STREAMS