]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/zstream.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Memory stream classes
4 // Author: Guilhem Lavaux
8 // Copyright: (c) Guilhem Lavaux
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11 #ifndef __WXZSTREAM_H__
12 #define __WXZSTREAM_H__
18 #include <wx/stream.h>
21 class wxZlibInputStream
: public wxFilterInputStream
{
23 wxZlibInputStream(wxInputStream
& stream
);
24 virtual ~wxZlibInputStream();
26 wxInputStream
& Read(void *buffer
, size_t size
);
27 off_t
SeekI(off_t pos
, wxSeekMode mode
= wxFromStart
);
30 size_t LastRead() const { return m_lastread
; }
36 unsigned char *m_z_buffer
;
38 struct z_stream_s m_inflate
;
41 class wxZlibOutputStream
: public wxFilterOutputStream
{
43 wxZlibOutputStream(wxOutputStream
& stream
);
44 virtual ~wxZlibOutputStream();
46 wxOutputStream
& Write(const void *buffer
, size_t size
);
47 off_t
SeekO(off_t pos
, wxSeekMode mode
= wxFromStart
);
50 size_t LastWrite() const { return m_lastwrite
; }
56 unsigned char *m_z_buffer
;
58 struct z_stream_s m_deflate
;