X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4cbfec1580bb0e546744fbe07675f8fba1ad49f2..ba49d2acf95d53517719c4fd9ac2ad5aaa13540b:/docs/doxygen/overviews/archive.h
diff --git a/docs/doxygen/overviews/archive.h b/docs/doxygen/overviews/archive.h
index 69aabb55dd..f789ff78cf 100644
--- a/docs/doxygen/overviews/archive.h
+++ b/docs/doxygen/overviews/archive.h
@@ -3,15 +3,17 @@
// Purpose: topic overview
// Author: wxWidgets team
// RCS-ID: $Id$
-// Licence: wxWindows license
+// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
/**
@page overview_archive Archive Formats
+@tableofcontents
+
The archive classes handle archive formats such as zip, tar, rar and cab.
-Currently wxZip and wxTar classes are included.
+Currently wxZip, wxTar and wxZlib classes are included.
For each archive type, there are the following classes (using zip here as an
example):
@@ -30,17 +32,6 @@ The classes are designed to handle archives on both seekable streams such as
disk files, or non-seekable streams such as pipes and sockets (see
@ref overview_archive_noseek).
-See also wxFileSystem.
-
-@li @ref overview_archive_create
-@li @ref overview_archive_extract
-@li @ref overview_archive_modify
-@li @ref overview_archive_byname
-@li @ref overview_archive_generic
-@li @ref overview_archive_noseek
-
-
-
@section overview_archive_create Creating an Archive
@@ -50,16 +41,16 @@ archive, then write the entry's data. Another call to PutNextEntry() closes the
current entry and begins the next. For example:
@code
-wxFFileOutputStream out(_T("test.zip"));
+wxFFileOutputStream out(wxT("test.zip"));
wxZipOutputStream zip(out);
wxTextOutputStream txt(zip);
wxString sep(wxFileName::GetPathSeparator());
-zip.PutNextEntry(_T("entry1.txt"));
-txt << _T("Some text for entry1.txt\n");
+zip.PutNextEntry(wxT("entry1.txt"));
+txt << wxT("Some text for entry1.txt\n");
-zip.PutNextEntry(_T("subdir") + sep + _T("entry2.txt"));
-txt << _T("Some text for subdir/entry2.txt\n");
+zip.PutNextEntry(wxT("subdir") + sep + wxT("entry2.txt"));
+txt << wxT("Some text for subdir/entry2.txt\n");
@endcode
The name of each entry can be a full path, which makes it possible to store
@@ -80,7 +71,7 @@ When there are no more entries, GetNextEntry() returns @NULL and sets Eof().
@code
auto_ptr entry;
-wxFFileInputStream in(_T("test.zip"));
+wxFFileInputStream in(wxT("test.zip"));
wxZipInputStream zip(in);
while (entry.reset(zip.GetNextEntry()), entry.get() != NULL)
@@ -111,8 +102,8 @@ archive. wxTempFileOutputStream can be helpful to do this.
For example to delete all entries matching the pattern "*.txt":
@code
-auto_ptr in(new wxFFileInputStream(_T("test.zip")));
-wxTempFileOutputStream out(_T("test.zip"));
+auto_ptr in(new wxFFileInputStream(wxT("test.zip")));
+wxTempFileOutputStream out(wxT("test.zip"));
wxZipInputStream inzip(*in);
wxZipOutputStream outzip(out);
@@ -125,7 +116,7 @@ outzip.CopyArchiveMetaData(inzip);
// call CopyEntry for each entry except those matching the pattern
while (entry.reset(inzip.GetNextEntry()), entry.get() != NULL)
- if (!entry->GetName().Matches(_T("*.txt")))
+ if (!entry->GetName().Matches(wxT("*.txt")))
if (!outzip.CopyEntry(entry.release(), inzip))
break;
@@ -167,7 +158,7 @@ auto_ptr entry;
wxString name = wxZipEntry::GetInternalName(localname);
// open the zip
-wxFFileInputStream in(_T("test.zip"));
+wxFFileInputStream in(wxT("test.zip"));
wxZipInputStream zip(in);
// call GetNextEntry() until the required internal name is found
@@ -195,7 +186,7 @@ wxZipEntry *entry;
ZipCatalog cat;
// open the zip
-wxFFileInputStream in(_T("test.zip"));
+wxFFileInputStream in(wxT("test.zip"));
wxZipInputStream zip(in);
// load the zip catalog
@@ -222,7 +213,7 @@ stream on the same archive:
@code
// opening another entry without closing the first requires another
// input stream for the same file
-wxFFileInputStream in2(_T("test.zip"));
+wxFFileInputStream in2(wxT("test.zip"));
wxZipInputStream zip2(in2);
if ((it = cat.find(wxZipEntry::GetInternalName(local2))) != cat.end())
zip2.OpenEntry(*it->second);
@@ -311,7 +302,7 @@ if (in->IsOk())
}
else
{
- wxLogError(_T("can't handle '%s'"), filename.c_str());
+ wxLogError(wxT("can't handle '%s'"), filename.c_str());
}
}
@endcode
@@ -361,7 +352,7 @@ attempts to update it if it is still around.
The documentation for each archive entry type gives the details of what
meta-data becomes available and when. For generic programming, when the worst
case must be assumed, you can rely on all the fields of wxArchiveEntry being
-fully populated when GetNextEntry() returns, with the the following exceptions:
+fully populated when GetNextEntry() returns, with the following exceptions:
@li wxArchiveEntry::GetSize(): Guaranteed to be available after the entry has
been read to wxInputStream::Eof(), or wxArchiveInputStream::CloseEntry()