]> git.saurik.com Git - wxWidgets.git/blob - src/common/archive.cpp
filename correction
[wxWidgets.git] / src / common / archive.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: archive.cpp
3 // Purpose: Streams for archive formats
4 // Author: Mike Wetherell
5 // RCS-ID: $Id$
6 // Copyright: (c) Mike Wetherell
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
9
10 // For compilers that support precompilation, includes "wx.h".
11 #include "wx/wxprec.h"
12
13 #ifdef __BORLANDC__
14 #pragma hdrstop
15 #endif
16
17 #ifndef WX_PRECOMP
18 #include "wx/defs.h"
19 #endif
20
21 #if wxUSE_STREAMS && wxUSE_ARCHIVE_STREAMS
22
23 #include "wx/archive.h"
24 #include "wx/link.h"
25
26 IMPLEMENT_ABSTRACT_CLASS(wxArchiveEntry, wxObject)
27 IMPLEMENT_ABSTRACT_CLASS(wxArchiveClassFactory, wxObject)
28
29 #if wxUSE_ZIPSTREAM
30 wxFORCE_LINK_MODULE(zipstrm)
31 #endif
32
33
34 /////////////////////////////////////////////////////////////////////////////
35 // wxArchiveInputStream
36
37 wxArchiveInputStream::wxArchiveInputStream(wxInputStream& stream,
38 wxMBConv& conv)
39 : wxFilterInputStream(stream),
40 m_conv(conv)
41 {
42 }
43
44
45 /////////////////////////////////////////////////////////////////////////////
46 // wxArchiveOutputStream
47
48 wxArchiveOutputStream::wxArchiveOutputStream(wxOutputStream& stream,
49 wxMBConv& conv)
50 : wxFilterOutputStream(stream),
51 m_conv(conv)
52 {
53 }
54
55
56 /////////////////////////////////////////////////////////////////////////////
57 // wxArchiveEntry
58
59 void wxArchiveEntry::SetNotifier(wxArchiveNotifier& notifier)
60 {
61 UnsetNotifier();
62 m_notifier = &notifier;
63 m_notifier->OnEntryUpdated(*this);
64 }
65
66 wxArchiveEntry& wxArchiveEntry::operator=(const wxArchiveEntry& WXUNUSED(e))
67 {
68 m_notifier = NULL;
69 return *this;
70 }
71
72 #endif // wxUSE_STREAMS && wxUSE_ARCHIVE_STREAMS