summaryrefslogtreecommitdiffstats
path: root/chrome/common/unzip.h
diff options
context:
space:
mode:
authorerikkay@google.com <erikkay@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-31 17:02:20 +0000
committererikkay@google.com <erikkay@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-31 17:02:20 +0000
commit02a9d6406c7047e6a5b81ddf2e1b8473ba1415c1 (patch)
treedbe1b3c08d4131ec53e2eff7d060d271bb43601e /chrome/common/unzip.h
parent3ba7f3741449eca4e44b6424ff6671adb168fbf5 (diff)
downloadchromium_src-02a9d6406c7047e6a5b81ddf2e1b8473ba1415c1.zip
chromium_src-02a9d6406c7047e6a5b81ddf2e1b8473ba1415c1.tar.gz
chromium_src-02a9d6406c7047e6a5b81ddf2e1b8473ba1415c1.tar.bz2
Add generic unzip support. This is to be used by extensions.
depends on http://codereview.chromium.org/16605 Review URL: http://codereview.chromium.org/16487 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7530 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/unzip.h')
-rw-r--r--chrome/common/unzip.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/chrome/common/unzip.h b/chrome/common/unzip.h
new file mode 100644
index 0000000..fc9aa64
--- /dev/null
+++ b/chrome/common/unzip.h
@@ -0,0 +1,20 @@
+// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_COMMON_UNZIP_H_
+#define CHROME_COMMON_UNZIP_H_
+
+#include <vector>
+
+#include "base/file_path.h"
+
+// Unzip the contents of zip_file into dest_dir. The complete paths of all
+// created files and directories are added to files if it is non-NULL.
+// Returns true on success. Does not clean up dest_dir on failure.
+// Does not support encrypted or password protected zip files.
+bool Unzip(const FilePath& zip_file, const FilePath& dest_dir,
+ std::vector<FilePath>* files);
+
+#endif // CHROME_COMMON_UNZIP_H_
+