Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(240)

Side by Side Diff: chrome/browser/component_updater/component_patcher.h

Issue 138553004: Move component updater artifacts into component_updater namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Component updates can be either differential updates or full updates. 5 // Component updates can be either differential updates or full updates.
6 // Full updates come in CRX format; differential updates come in CRX-style 6 // Full updates come in CRX format; differential updates come in CRX-style
7 // archives, but have a different magic number. They contain "commands.json", a 7 // archives, but have a different magic number. They contain "commands.json", a
8 // list of commands for the patcher to follow. The patcher uses these commands, 8 // list of commands for the patcher to follow. The patcher uses these commands,
9 // the other files in the archive, and the files from the existing installation 9 // the other files in the archive, and the files from the existing installation
10 // of the component to create the contents of a full update, which is then 10 // of the component to create the contents of a full update, which is then
(...skipping 18 matching lines...) Expand all
29 #define CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_PATCHER_H_ 29 #define CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_PATCHER_H_
30 30
31 #include "base/basictypes.h" 31 #include "base/basictypes.h"
32 #include "base/compiler_specific.h" 32 #include "base/compiler_specific.h"
33 #include "chrome/browser/component_updater/component_unpacker.h" 33 #include "chrome/browser/component_updater/component_unpacker.h"
34 34
35 namespace base { 35 namespace base {
36 class FilePath; 36 class FilePath;
37 } 37 }
38 38
39 namespace component_updater {
40
39 class ComponentInstaller; 41 class ComponentInstaller;
40 42
41 // Applies a delta patch to a single file. Specifically, creates a file at 43 // Applies a delta patch to a single file. Specifically, creates a file at
42 // |output_file| using |input_file| patched according to the algorithm 44 // |output_file| using |input_file| patched according to the algorithm
43 // specified by |patch_type| using |patch_file|. Sets the value of error to 45 // specified by |patch_type| using |patch_file|. Sets the value of error to
44 // the error code of the failing patch operation, if there is such a failure. 46 // the error code of the failing patch operation, if there is such a failure.
45 class ComponentPatcher { 47 class ComponentPatcher {
46 public: 48 public:
47 // The type of a patch file. 49 // The type of a patch file.
48 enum PatchType { 50 enum PatchType {
(...skipping 27 matching lines...) Expand all
76 // is then installed normally. 78 // is then installed normally.
77 // The non-differential files are written into the |unpack_dir| directory. 79 // The non-differential files are written into the |unpack_dir| directory.
78 // Sets |error| to the error code of the first failing patch operation. 80 // Sets |error| to the error code of the first failing patch operation.
79 ComponentUnpacker::Error DifferentialUpdatePatch( 81 ComponentUnpacker::Error DifferentialUpdatePatch(
80 const base::FilePath& input_dir, 82 const base::FilePath& input_dir,
81 const base::FilePath& unpack_dir, 83 const base::FilePath& unpack_dir,
82 ComponentPatcher* component_patcher, 84 ComponentPatcher* component_patcher,
83 ComponentInstaller* installer, 85 ComponentInstaller* installer,
84 int* error); 86 int* error);
85 87
88 } // namespace component_updater
89
86 #endif // CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_PATCHER_H_ 90 #endif // CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_PATCHER_H_
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_main.cc ('k') | chrome/browser/component_updater/component_patcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698