X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/00375592f92f68c4ca3f44d8e839bcfd47adc4e1..fc17828ab2cb3dc5dd22d5634ce4f6764e1373fc:/docs/latex/wx/zipstrm.tex diff --git a/docs/latex/wx/zipstrm.tex b/docs/latex/wx/zipstrm.tex index 65e0f3f673..f907245f17 100644 --- a/docs/latex/wx/zipstrm.tex +++ b/docs/latex/wx/zipstrm.tex @@ -19,7 +19,7 @@ for details. \wxheading{See also} \helpref{Archive formats such as zip}{wxarc}\\ -\helpref{Generic archive programming}{wxarcgeneric} +\helpref{Generic archive programming}{wxarcgeneric}\\ \helpref{wxZipEntry}{wxzipentry}\\ \helpref{wxZipInputStream}{wxzipinputstream}\\ \helpref{wxZipOutputStream}{wxzipoutputstream} @@ -433,6 +433,9 @@ the wxZipInputStream then returns the entry's data. Eof() becomes true after an attempt has been made to read past the end of the entry's data. When there are no more entries, GetNextEntry() returns NULL and sets Eof(). +Note that in general zip entries are not seekable, and +wxZipInputStream::SeekI() always returns wxInvalidOffset. + \wxheading{Derived from} \helpref{wxArchiveInputStream}{wxarchiveinputstream} @@ -442,9 +445,9 @@ When there are no more entries, GetNextEntry() returns NULL and sets Eof(). \wxheading{Data structures} -{\small \begin{verbatim} -typedef wxZipEntry entry\_type -\end{verbatim}} +\begin{verbatim} +typedef wxZipEntry entry_type +\end{verbatim} \wxheading{See also} @@ -459,13 +462,22 @@ typedef wxZipEntry entry\_type \func{}{wxZipInputStream}{\param{wxInputStream\& }{stream}, \param{wxMBConv\& }{conv = wxConvLocal}} +\func{}{wxZipInputStream}{\param{wxInputStream*}{stream}, \param{wxMBConv\& }{conv = wxConvLocal}} + Constructor. In a Unicode build the second parameter {\tt conv} is used to translate the filename and comment fields into Unicode. It has no effect on the stream's data. +If the parent stream is passed as a pointer then the new filter stream +takes ownership of it. If it is passed by reference then it does not. + \func{}{wxZipInputStream}{\param{const wxString\& }{archive}, \param{const wxString\& }{file}} -Compatibility constructor. +Compatibility constructor (requires WXWIN\_COMPATIBILITY\_2\_6). + +When this constructor is used, an emulation of seeking is +switched on for compatibility with previous versions. Note however, +that it is deprecated. \membersection{wxZipInputStream::CloseEntry}\label{wxzipinputstreamcloseentry} @@ -482,7 +494,7 @@ the current entry first. Returns the zip comment. -This is stored a the end of the zip, therefore when reading a zip +This is stored at the end of the zip, therefore when reading a zip from a non-seekable stream, it returns the empty string until the end of the zip has been reached, i.e. when GetNextEntry() returns NULL. @@ -601,12 +613,17 @@ entry and begins the next. \func{}{wxZipOutputStream}{\param{wxOutputStream\& }{stream}, \param{int }{level = -1}, \param{wxMBConv\& }{conv = wxConvLocal}} +\func{}{wxZipOutputStream}{\param{wxOutputStream*}{stream}, \param{int }{level = -1}, \param{wxMBConv\& }{conv = wxConvLocal}} + Constructor. {\tt level} is the compression level to use. It can be a value between 0 and 9 or -1 to use the default value which currently is equivalent to 6. +If the parent stream is passed as a pointer then the new filter stream +takes ownership of it. If it is passed by reference then it does not. + In a Unicode build the third parameter {\tt conv} is used to translate -the filename and comment fields to Unicode. It has no effect on the +the filename and comment fields to an 8-bit encoding. It has no effect on the stream's data. @@ -622,7 +639,7 @@ writing the zip if it has not been called already. \func{bool}{Close}{\void} -Finishes writing the zip, returning true if successfully. +Finishes writing the zip, returning true if successful. Called by the destructor if not called explicitly.