2 % automatically generated by HelpGen $Revision$ from
3 % wx/zipstrm.h at 16/Sep/04 12:19:29
6 \section{\class{wxZipClassFactory
}}\label{wxzipclassfactory
}
8 Class factory for the zip archive format. See the base class
11 \wxheading{Derived from
}
13 \helpref{wxArchiveClassFactory
}{wxarchiveclassfactory
}
15 \wxheading{Include files
}
21 \helpref{wxBase
}{librarieslist
}
25 \helpref{Archive formats such as zip
}{wxarc
}\\
26 \helpref{Generic archive programming
}{wxarcgeneric
}\\
27 \helpref{wxZipEntry
}{wxzipentry
}\\
28 \helpref{wxZipInputStream
}{wxzipinputstream
}\\
29 \helpref{wxZipOutputStream
}{wxzipoutputstream
}
33 % automatically generated by HelpGen $Revision$ from
34 % wx/zipstrm.h at 16/Sep/04 12:19:29
37 \section{\class{wxZipEntry
}}\label{wxzipentry
}
39 Holds the meta-data for an entry in a zip.
41 \wxheading{Derived from
}
43 \helpref{wxArchiveEntry
}{wxarchiveentry
}
45 \wxheading{Include files
}
51 \helpref{wxBase
}{librarieslist
}
53 \wxheading{Data structures
}
55 Constants for
\helpref{Get/SetMethod
}{wxzipentrymethod
}:
58 // Compression Method, only
0 (store) and
8 (deflate) are supported here
69 wxZIP_METHOD_TOKENIZE,
71 wxZIP_METHOD_DEFLATE64,
72 wxZIP_METHOD_BZIP2 =
12,
73 wxZIP_METHOD_DEFAULT =
0xffff
78 Constants for
\helpref{Get/SetSystemMadeBy
}{wxzipentrysystemmadeby
}:
81 // Originating File-System.
83 // These are Pkware's values. Note that Info-zip disagree on some of them,
93 wxZIP_SYSTEM_ATARI_ST,
94 wxZIP_SYSTEM_OS2_HPFS,
95 wxZIP_SYSTEM_MACINTOSH,
96 wxZIP_SYSTEM_Z_SYSTEM,
98 wxZIP_SYSTEM_WINDOWS_NTFS,
101 wxZIP_SYSTEM_ACORN_RISC,
103 wxZIP_SYSTEM_ALTERNATE_MVS,
111 Constants for
\helpref{Get/SetExternalAttributes
}{wxzipentryexternalattributes
}:
114 // Dos/Win file attributes
118 wxZIP_A_RDONLY =
0x01,
119 wxZIP_A_HIDDEN =
0x02,
120 wxZIP_A_SYSTEM =
0x04,
121 wxZIP_A_SUBDIR =
0x10,
129 Constants for
\helpref{Get/SetFlags
}{wxzipentrygetflags
}:
132 // Values for the flags field in the zip headers
136 wxZIP_ENCRYPTED =
0x0001,
137 wxZIP_DEFLATE_NORMAL =
0x0000, // normal compression
138 wxZIP_DEFLATE_EXTRA =
0x0002, // extra compression
139 wxZIP_DEFLATE_FAST =
0x0004, // fast compression
140 wxZIP_DEFLATE_SUPERFAST =
0x0006, // superfast compression
141 wxZIP_DEFLATE_MASK =
0x0006,
142 wxZIP_SUMS_FOLLOW =
0x0008, // crc and sizes come after the data
143 wxZIP_ENHANCED =
0x0010,
144 wxZIP_PATCH =
0x0020,
145 wxZIP_STRONG_ENC =
0x0040,
146 wxZIP_UNUSED =
0x0F80,
147 wxZIP_RESERVED =
0xF000
154 \helpref{Archive formats such as zip
}{wxarc
}\\
155 \helpref{wxZipInputStream
}{wxzipinputstream
}\\
156 \helpref{wxZipOutputStream
}{wxzipoutputstream
}\\
157 \helpref{wxZipNotifier
}{wxzipnotifier
}
159 \wxheading{Field availability
}
161 When reading a zip from a stream that is seekable,
162 \helpref{GetNextEntry()
}{wxzipinputstreamgetnextentry
} returns
163 a fully populated wxZipEntry object except for
164 \helpref{wxZipEntry::GetLocalExtra()
}{wxzipentrylocalextra
}. GetLocalExtra()
165 becomes available when the entry is opened, either by calling
166 \helpref{wxZipInputStream::OpenEntry
}{wxzipinputstreamopenentry
} or by
167 making an attempt to read the entry's data.
169 For zips on
\helpref{non-seekable
}{wxarcnoseek
} streams, the following
170 fields are always available when GetNextEntry() returns:
172 \helpref{GetDateTime
}{wxarchiveentrydatetime
}\\
173 \helpref{GetInternalFormat
}{wxarchiveentrygetinternalformat
}\\
174 \helpref{GetInternalName
}{wxzipentrygetinternalname
}\\
175 \helpref{GetFlags
}{wxzipentrygetflags
}\\
176 \helpref{GetLocalExtra
}{wxzipentrylocalextra
}\\
177 \helpref{GetMethod
}{wxzipentrymethod
}\\
178 \helpref{GetName
}{wxarchiveentryname
}\\
179 \helpref{GetOffset
}{wxarchiveentrygetoffset
}\\
180 \helpref{IsDir
}{wxarchiveentryisdir
}
182 The following fields are also usually available when GetNextEntry()
183 returns, however, if the zip was also written to a non-seekable stream
184 the zipper is permitted to store them after the entry's data. In that
185 case they become available when the entry's data has been read to Eof(),
186 or
\helpref{CloseEntry()
}{wxarchiveinputstreamcloseentry
} has been called.
187 {\tt (GetFlags() \& wxZIP
\_SUMS\_FOLLOW) !=
0} indicates that one or
188 more of these come after the data:
190 \helpref{GetCompressedSize
}{wxzipentrygetcompressedsize
}\\
191 \helpref{GetCrc
}{wxzipentrygetcrc
}\\
192 \helpref{GetSize
}{wxarchiveentrysize
}
194 The following are stored at the end of the zip, and become available
195 when the end of the zip has been reached, i.e. after GetNextEntry()
196 returns NULL and Eof() is true:
198 \helpref{GetComment
}{wxzipentrycomment
}\\
199 \helpref{GetExternalAttributes
}{wxzipentryexternalattributes
}\\
200 \helpref{GetExtra
}{wxzipentryextra
}\\
201 \helpref{GetMode
}{wxzipentrymode
}\\
202 \helpref{GetSystemMadeBy
}{wxzipentrysystemmadeby
}\\
203 \helpref{IsReadOnly
}{wxarchiveentryisreadonly
}\\
204 \helpref{IsMadeByUnix
}{wxzipentryismadebyunix
}\\
205 \helpref{IsText
}{wxzipentryistext
}
208 \latexignore{\rtfignore{\wxheading{Members
}}}
211 \membersection{wxZipEntry::wxZipEntry
}\label{wxzipentrywxzipentry
}
213 \func{}{wxZipEntry
}{\param{const wxString\&
}{name = wxEmptyString
},
\param{const wxDateTime\&
}{dt = wxDateTime::Now()
},
\param{off
\_t }{size = wxInvalidOffset
}}
217 \func{}{wxZipEntry
}{\param{const wxZipEntry\&
}{entry
}}
222 \membersection{wxZipEntry::Clone
}\label{wxzipentryclone
}
224 \constfunc{wxZipEntry*
}{Clone
}{\void}
226 Make a copy of this entry.
229 \membersection{wxZipEntry::Get/SetComment
}\label{wxzipentrycomment
}
231 \constfunc{wxString
}{GetComment
}{\void}
233 \func{void
}{SetComment
}{\param{const wxString\&
}{comment
}}
235 A short comment for this entry.
238 \membersection{wxZipEntry::GetCompressedSize
}\label{wxzipentrygetcompressedsize
}
240 \constfunc{off
\_t}{GetCompressedSize
}{\void}
242 The compressed size of this entry in bytes.
245 \membersection{wxZipEntry::GetCrc
}\label{wxzipentrygetcrc
}
247 \constfunc{wxUint32
}{GetCrc
}{\void}
249 CRC32 for this entry's data.
252 \membersection{wxZipEntry::Get/SetExternalAttributes
}\label{wxzipentryexternalattributes
}
254 \constfunc{wxUint32
}{GetExternalAttributes
}{\void}
256 \func{void
}{SetExternalAttributes
}{\param{wxUint32
}{attr
}}
258 The low
8 bits are always the DOS/Windows file attributes for this entry.
259 The values of these attributes are given in the
260 enumeration
{\tt wxZipAttributes
}.
262 The remaining bits can store platform specific permission bits or
263 attributes, and their meaning depends on the value
264 of
\helpref{SetSystemMadeBy()
}{wxzipentrysystemmadeby
}.
265 If
\helpref{IsMadeByUnix()
}{wxzipentryismadebyunix
} is true then the
266 high
16 bits are unix mode bits.
268 The following other accessors access these bits:
270 \helpref{IsReadOnly/SetIsReadOnly
}{wxarchiveentryisreadonly
}\\
271 \helpref{IsDir/SetIsDir
}{wxarchiveentryisdir
}\\
272 \helpref{Get/SetMode
}{wxzipentrymode
}
275 \membersection{wxZipEntry::Get/SetExtra
}\label{wxzipentryextra
}
277 \constfunc{const char*
}{GetExtra
}{\void}
279 \constfunc{size
\_t}{GetExtraLen
}{\void}
281 \func{void
}{SetExtra
}{\param{const char*
}{extra
},
\param{size
\_t }{len
}}
283 The extra field from the entry's central directory record.
285 The extra field is used to store platform or application specific
286 data. See Pkware's
document 'appnote.txt' for information on its format.
289 \membersection{wxZipEntry::GetFlags
}\label{wxzipentrygetflags
}
291 \constfunc{int
}{GetFlags
}{\void}
293 Returns a combination of the bits flags in the enumeration
{\tt wxZipFlags
}.
296 \membersection{wxZipEntry::GetInternalName
}\label{wxzipentrygetinternalname
}
298 \constfunc{wxString
}{GetInternalName
}{\void}
300 Returns the entry's filename in the internal format used within the
301 archive. The name can include directory components, i.e. it can be a
304 The names of directory entries are returned without any trailing path
305 separator. This gives a canonical name that can be used in comparisons.
307 \func{wxString
}{GetInternalName
}{\param{const wxString\&
}{name
},
\param{wxPathFormat
}{format = wxPATH
\_NATIVE},
\param{bool*
}{pIsDir = NULL
}}
309 A static member that translates a filename into the internal format used
310 within the archive. If the third parameter is provided, the bool pointed
311 to is set to indicate whether the name looks like a directory name
312 (i.e. has a trailing path separator).
316 \helpref{Looking up an archive entry by name
}{wxarcbyname
}
319 \membersection{wxZipEntry::Get/SetLocalExtra
}\label{wxzipentrylocalextra
}
321 \constfunc{const char*
}{GetLocalExtra
}{\void}
323 \constfunc{size
\_t}{GetLocalExtraLen
}{\void}
325 \func{void
}{SetLocalExtra
}{\param{const char*
}{extra
},
\param{size
\_t }{len
}}
327 The extra field from the entry's local record.
329 The extra field is used to store platform or application specific
330 data. See Pkware's
document 'appnote.txt' for information on its format.
333 \membersection{wxZipEntry::Get/SetMethod
}\label{wxzipentrymethod
}
335 \constfunc{int
}{GetMethod
}{\void}
337 \func{void
}{SetMethod
}{\param{int
}{method
}}
339 The compression method. The enumeration
{\tt wxZipMethod
} lists the
342 The default constructor sets this to wxZIP
\_METHOD\_DEFAULT,
343 which allows
\helpref{wxZipOutputStream
}{wxzipoutputstream
} to
344 choose the method when writing the entry.
347 \membersection{wxZipEntry::Get/SetMode
}\label{wxzipentrymode
}
349 \constfunc{int
}{GetMode
}{\void}
351 If
\helpref{IsMadeByUnix()
}{wxzipentryismadebyunix
} is true then
352 returns the unix permission bits stored in
353 \helpref{GetExternalAttributes()
}{wxzipentryexternalattributes
}.
354 Otherwise synthesises them from the DOS attributes.
356 \func{void
}{SetMode
}{\param{int
}{mode
}}
358 Sets the DOS attributes
359 in
\helpref{GetExternalAttributes()
}{wxzipentryexternalattributes
}
360 to be consistent with the
{\tt mode
} given.
362 If
\helpref{IsMadeByUnix()
}{wxzipentryismadebyunix
} is true then also
363 stores
{\tt mode
} in GetExternalAttributes().
365 Note that the default constructor
366 sets
\helpref{GetSystemMadeBy()
}{wxzipentrysystemmadeby
} to
367 wxZIP
\_SYSTEM\_MSDOS by default. So to be able to store unix
368 permissions when creating zips, call SetSystemMadeBy(wxZIP
\_SYSTEM\_UNIX).
371 \membersection{wxZipEntry::SetNotifier
}\label{wxzipentrynotifier
}
373 \func{void
}{SetNotifier
}{\param{wxZipNotifier\&
}{notifier
}}
375 \func{void
}{UnsetNotifier
}{\void}
377 Sets the
\helpref{notifier
}{wxzipnotifier
} for this entry.
378 Whenever the
\helpref{wxZipInputStream
}{wxzipinputstream
} updates
379 this entry, it will then invoke the associated
380 notifier's
\helpref{OnEntryUpdated
}{wxzipnotifieronentryupdated
}
383 Setting a notifier is not usually necessary. It is used to handle
384 certain cases when modifying an zip in a pipeline (i.e. between
385 non-seekable streams).
389 \helpref{Archives on non-seekable streams
}{wxarcnoseek
}\\
390 \helpref{wxZipNotifier
}{wxzipnotifier
}
393 \membersection{wxZipEntry::Get/SetSystemMadeBy
}\label{wxzipentrysystemmadeby
}
395 \constfunc{int
}{GetSystemMadeBy
}{\void}
397 \func{void
}{SetSystemMadeBy
}{\param{int
}{system
}}
399 The originating file-system. The default constructor sets this to
400 wxZIP
\_SYSTEM\_MSDOS. Set it to wxZIP
\_SYSTEM\_UNIX in order to be
401 able to store unix permissions using
\helpref{SetMode()
}{wxzipentrymode
}.
404 \membersection{wxZipEntry::IsMadeByUnix
}\label{wxzipentryismadebyunix
}
406 \constfunc{bool
}{IsMadeByUnix
}{\void}
408 Returns true if
\helpref{GetSystemMadeBy()
}{wxzipentrysystemmadeby
}
409 is a flavour of unix.
412 \membersection{wxZipEntry::IsText/SetIsText
}\label{wxzipentryistext
}
414 \constfunc{bool
}{IsText
}{\void}
416 \func{void
}{SetIsText
}{\param{bool
}{isText = true
}}
418 Indicates that this entry's data is text in an
8-bit encoding.
421 \membersection{wxZipEntry::operator=
}\label{wxzipentryoperatorassign
}
423 \func{wxZipEntry\& operator
}{operator=
}{\param{const wxZipEntry\&
}{entry
}}
429 % automatically generated by HelpGen $Revision$ from
430 % wx/zipstrm.h at 16/Sep/04 12:19:29
433 \section{\class{wxZipInputStream
}}\label{wxzipinputstream
}
435 Input stream for reading zip files.
437 \helpref{GetNextEntry()
}{wxzipinputstreamgetnextentry
} returns an
438 \helpref{wxZipEntry
}{wxzipentry
} object containing the meta-data
439 for the next entry in the zip (and gives away ownership). Reading from
440 the wxZipInputStream then returns the entry's data. Eof() becomes true
441 after an attempt has been made to read past the end of the entry's data.
442 When there are no more entries, GetNextEntry() returns NULL and sets Eof().
444 Note that in general zip entries are not seekable, and
445 wxZipInputStream::SeekI() always returns wxInvalidOffset.
447 \wxheading{Derived from
}
449 \helpref{wxArchiveInputStream
}{wxarchiveinputstream
}
451 \wxheading{Include files
}
457 \helpref{wxBase
}{librarieslist
}
459 \wxheading{Data structures
}
461 typedef wxZipEntry entry_type
466 \helpref{Archive formats such as zip
}{wxarc
}\\
467 \helpref{wxZipEntry
}{wxzipentry
}\\
468 \helpref{wxZipOutputStream
}{wxzipoutputstream
}
470 \latexignore{\rtfignore{\wxheading{Members
}}}
473 \membersection{wxZipInputStream::wxZipInputStream
}\label{wxzipinputstreamwxzipinputstream
}
475 \func{}{wxZipInputStream
}{\param{wxInputStream\&
}{stream
},
\param{wxMBConv\&
}{conv = wxConvLocal
}}
477 \func{}{wxZipInputStream
}{\param{wxInputStream*
}{stream
},
\param{wxMBConv\&
}{conv = wxConvLocal
}}
479 Constructor. In a Unicode build the second parameter
{\tt conv
} is
480 used to translate the filename and comment fields into Unicode. It has
481 no effect on the stream's data.
483 If the parent stream is passed as a pointer then the new filter stream
484 takes ownership of it. If it is passed by reference then it does not.
486 \func{}{wxZipInputStream
}{\param{const wxString\&
}{archive
},
\param{const wxString\&
}{file
}}
488 Compatibility constructor (requires WXWIN
\_COMPATIBILITY\_2\_6).
490 When this constructor is used, an emulation of seeking is
491 switched on for compatibility with previous versions. Note however,
492 that it is deprecated.
495 \membersection{wxZipInputStream::CloseEntry
}\label{wxzipinputstreamcloseentry
}
497 \func{bool
}{CloseEntry
}{\void}
499 Closes the current entry. On a non-seekable stream reads to the end of
500 the current entry first.
503 \membersection{wxZipInputStream::GetComment
}\label{wxzipinputstreamgetcomment
}
505 \func{wxString
}{GetComment
}{\void}
507 Returns the zip comment.
509 This is stored at the end of the zip, therefore when reading a zip
510 from a non-seekable stream, it returns the empty string until the
511 end of the zip has been reached, i.e. when GetNextEntry() returns
515 \membersection{wxZipInputStream::GetNextEntry
}\label{wxzipinputstreamgetnextentry
}
517 \func{wxZipEntry*
}{GetNextEntry
}{\void}
519 Closes the current entry if one is open, then reads the meta-data for
520 the next entry and returns it in a
\helpref{wxZipEntry
}{wxzipentry
}
521 object, giving away ownership. The stream is then open and can be read.
524 \membersection{wxZipInputStream::GetTotalEntries
}\label{wxzipinputstreamgettotalentries
}
526 \func{int
}{GetTotalEntries
}{\void}
528 For a zip on a seekable stream returns the total number of entries in
529 the zip. For zips on non-seekable streams returns the number of entries
530 returned so far by
\helpref{GetNextEntry()
}{wxzipinputstreamgetnextentry
}.
533 \membersection{wxZipInputStream::OpenEntry
}\label{wxzipinputstreamopenentry
}
535 \func{bool
}{OpenEntry
}{\param{wxZipEntry\&
}{entry
}}
537 Closes the current entry if one is open, then opens the entry specified
538 by the
{\it entry
} object.
540 {\it entry
} should be from the same zip file, and the zip should
541 be on a seekable stream.
545 \helpref{Looking up an archive entry by name
}{wxarcbyname
}
549 % automatically generated by HelpGen $Revision$ from
550 % wx/zipstrm.h at 16/Sep/04 12:19:29
553 \section{\class{wxZipNotifier
}}\label{wxzipnotifier
}
555 If you need to know when a
\helpref{wxZipInputStream
}{wxzipinputstream
}
556 updates a
\helpref{wxZipEntry
}{wxzipentry
},
557 you can create a notifier by deriving from this abstract base class,
558 overriding
\helpref{OnEntryUpdated()
}{wxzipnotifieronentryupdated
}.
559 An instance of your notifier class can then be assigned to wxZipEntry
560 objects, using
\helpref{wxZipEntry::SetNotifier()
}{wxzipentrynotifier
}.
562 Setting a notifier is not usually necessary. It is used to handle
563 certain cases when modifying an zip in a pipeline (i.e. between
564 non-seekable streams).
565 See '
\helpref{Archives on non-seekable streams
}{wxarcnoseek
}'.
567 \wxheading{Derived from
}
571 \wxheading{Include files
}
577 \helpref{wxBase
}{librarieslist
}
581 \helpref{Archives on non-seekable streams
}{wxarcnoseek
}\\
582 \helpref{wxZipEntry
}{wxzipentry
}\\
583 \helpref{wxZipInputStream
}{wxzipinputstream
}\\
584 \helpref{wxZipOutputStream
}{wxzipoutputstream
}
586 \latexignore{\rtfignore{\wxheading{Members
}}}
589 \membersection{wxZipNotifier::OnEntryUpdated
}\label{wxzipnotifieronentryupdated
}
591 \func{void
}{OnEntryUpdated
}{\param{wxZipEntry\&
}{entry
}}
593 Override this to receive notifications when
594 an
\helpref{wxZipEntry
}{wxzipentry
} object changes.
598 % automatically generated by HelpGen $Revision$ from
599 % wx/zipstrm.h at 16/Sep/04 12:19:29
602 \section{\class{wxZipOutputStream
}}\label{wxzipoutputstream
}
604 Output stream for writing zip files.
606 \helpref{PutNextEntry()
}{wxzipoutputstreamputnextentry
} is used to create
607 a new entry in the output zip, then the entry's data is written to the
608 wxZipOutputStream. Another call to PutNextEntry() closes the current
609 entry and begins the next.
611 \wxheading{Derived from
}
613 \helpref{wxArchiveOutputStream
}{wxarchiveoutputstream
}
615 \wxheading{Include files
}
621 \helpref{wxBase
}{librarieslist
}
625 \helpref{Archive formats such as zip
}{wxarc
}\\
626 \helpref{wxZipEntry
}{wxzipentry
}\\
627 \helpref{wxZipInputStream
}{wxzipinputstream
}
629 \latexignore{\rtfignore{\wxheading{Members
}}}
632 \membersection{wxZipOutputStream::wxZipOutputStream
}\label{wxzipoutputstreamwxzipoutputstream
}
634 \func{}{wxZipOutputStream
}{\param{wxOutputStream\&
}{stream
},
\param{int
}{level = -
1},
\param{wxMBConv\&
}{conv = wxConvLocal
}}
636 \func{}{wxZipOutputStream
}{\param{wxOutputStream*
}{stream
},
\param{int
}{level = -
1},
\param{wxMBConv\&
}{conv = wxConvLocal
}}
638 Constructor.
{\tt level
} is the compression level to use.
639 It can be a value between
0 and
9 or -
1 to use the default value
640 which currently is equivalent to
6.
642 If the parent stream is passed as a pointer then the new filter stream
643 takes ownership of it. If it is passed by reference then it does not.
645 In a Unicode build the third parameter
{\tt conv
} is used to translate
646 the filename and comment fields to an
8-bit encoding. It has no effect on the
650 \membersection{wxZipOutputStream::
\destruct{wxZipOutputStream
}}\label{wxzipoutputstreamdtor
}
652 \func{}{\destruct{wxZipOutputStream
}}{\void}
654 The destructor calls
\helpref{Close()
}{wxzipoutputstreamclose
} to finish
655 writing the zip if it has not been called already.
658 \membersection{wxZipOutputStream::Close
}\label{wxzipoutputstreamclose
}
660 \func{bool
}{Close
}{\void}
662 Finishes writing the zip, returning true if successful.
663 Called by the destructor if not called explicitly.
666 \membersection{wxZipOutputStream::CloseEntry
}\label{wxzipoutputstreamcloseentry
}
668 \func{bool
}{CloseEntry
}{\void}
670 Close the current entry. It is called implicitly whenever another new
671 entry is created with
\helpref{CopyEntry()
}{wxzipoutputstreamcopyentry
}
672 or
\helpref{PutNextEntry()
}{wxzipoutputstreamputnextentry
}, or
673 when the zip is closed.
676 \membersection{wxZipOutputStream::CopyArchiveMetaData
}\label{wxzipoutputstreamcopyarchivemetadata
}
678 \func{bool
}{CopyArchiveMetaData
}{\param{wxZipInputStream\&
}{inputStream
}}
680 Transfers the zip comment from the
\helpref{wxZipInputStream
}{wxzipinputstream
}
681 to this output stream.
684 \membersection{wxZipOutputStream::CopyEntry
}\label{wxzipoutputstreamcopyentry
}
686 \func{bool
}{CopyEntry
}{\param{wxZipEntry*
}{entry
},
\param{wxZipInputStream\&
}{inputStream
}}
688 Takes ownership of
{\tt entry
} and uses it to create a new entry
689 in the zip.
{\tt entry
} is then opened in
{\tt inputStream
} and its contents
690 copied to this stream.
692 CopyEntry() is much more efficient than transferring the data using
693 Read() and Write() since it will copy them without decompressing and
696 For zips on seekable streams,
{\tt entry
} must be from the same zip file
697 as
{\tt stream
}. For non-seekable streams,
{\tt entry
} must also be the
698 last thing read from
{\tt inputStream
}.
701 \membersection{wxZipOutputStream::Get/SetLevel
}\label{wxzipoutputstreamlevel
}
703 \constfunc{int
}{GetLevel
}{\void}
705 \func{void
}{SetLevel
}{\param{int
}{level
}}
707 Set the compression level that will be used the next time an entry is
708 created. It can be a value between
0 and
9 or -
1 to use the default value
709 which currently is equivalent to
6.
712 \membersection{wxZipOutputStream::PutNextDirEntry
}\label{wxzipoutputstreamputnextdirentry
}
714 \func{bool
}{PutNextDirEntry
}{\param{const wxString\&
}{name
},
\param{const wxDateTime\&
}{dt = wxDateTime::Now()
}}
716 Create a new directory entry
717 (see
\helpref{wxArchiveEntry::IsDir()
}{wxarchiveentryisdir
})
718 with the given name and timestamp.
720 \helpref{PutNextEntry()
}{wxzipoutputstreamputnextentry
} can
721 also be used to create directory entries, by supplying a name with
722 a trailing path separator.
725 \membersection{wxZipOutputStream::PutNextEntry
}\label{wxzipoutputstreamputnextentry
}
727 \func{bool
}{PutNextEntry
}{\param{wxZipEntry*
}{entry
}}
729 Takes ownership of
{\tt entry
} and uses it to create a new entry
732 \func{bool
}{PutNextEntry
}{\param{const wxString\&
}{name
},
\param{const wxDateTime\&
}{dt = wxDateTime::Now()
},
\param{off
\_t }{size = wxInvalidOffset
}}
734 Create a new entry with the given name, timestamp and size.
737 \membersection{wxZipOutputStream::SetComment
}\label{wxzipoutputstreamsetcomment
}
739 \func{void
}{SetComment
}{\param{const wxString\&
}{comment
}}
741 Sets a comment for the zip as a whole. It is written at the end of the