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

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

Issue 25909005: Use UtilityProcessHost to patch files. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@nonblocking
Patch Set: sorin@ review + rebase to LKGR r253860 Created 6 years, 9 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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 #ifndef CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_ 5 #ifndef CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_
6 #define CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_ 6 #define CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 12 matching lines...) Expand all
23 class URLRequest; 23 class URLRequest;
24 } 24 }
25 25
26 namespace content { 26 namespace content {
27 class ResourceThrottle; 27 class ResourceThrottle;
28 } 28 }
29 29
30 namespace component_updater { 30 namespace component_updater {
31 31
32 class OnDemandTester; 32 class OnDemandTester;
33 class ComponentPatcher;
34 33
35 // Component specific installers must derive from this class and implement 34 // Component specific installers must derive from this class and implement
36 // OnUpdateError() and Install(). A valid instance of this class must be 35 // OnUpdateError() and Install(). A valid instance of this class must be
37 // given to ComponentUpdateService::RegisterComponent(). 36 // given to ComponentUpdateService::RegisterComponent().
38 class ComponentInstaller { 37 class ComponentInstaller {
39 public : 38 public :
40 // Called by the component updater on the UI thread when there was a 39 // Called by the component updater on the UI thread when there was a
41 // problem unpacking or verifying the component. |error| is a non-zero 40 // problem unpacking or verifying the component. |error| is a non-zero
42 // value which is only meaningful to the component updater. 41 // value which is only meaningful to the component updater.
43 virtual void OnUpdateError(int error) = 0; 42 virtual void OnUpdateError(int error) = 0;
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 // pings are disabled. 170 // pings are disabled.
172 virtual GURL PingUrl() = 0; 171 virtual GURL PingUrl() = 0;
173 // Parameters added to each url request. It can be null if none are needed. 172 // Parameters added to each url request. It can be null if none are needed.
174 virtual std::string ExtraRequestParams() = 0; 173 virtual std::string ExtraRequestParams() = 0;
175 // How big each update request can be. Don't go above 2000. 174 // How big each update request can be. Don't go above 2000.
176 virtual size_t UrlSizeLimit() = 0; 175 virtual size_t UrlSizeLimit() = 0;
177 // The source of contexts for all the url requests. 176 // The source of contexts for all the url requests.
178 virtual net::URLRequestContextGetter* RequestContext() = 0; 177 virtual net::URLRequestContextGetter* RequestContext() = 0;
179 // True means that all ops are performed in this process. 178 // True means that all ops are performed in this process.
180 virtual bool InProcess() = 0; 179 virtual bool InProcess() = 0;
181 // Creates a new ComponentPatcher in a platform-specific way. This is useful
182 // for dependency injection.
183 virtual ComponentPatcher* CreateComponentPatcher() = 0;
184 // True means that this client can handle delta updates. 180 // True means that this client can handle delta updates.
185 virtual bool DeltasEnabled() const = 0; 181 virtual bool DeltasEnabled() const = 0;
186 // True means that the background downloader can be used for downloading 182 // True means that the background downloader can be used for downloading
187 // non on-demand components. 183 // non on-demand components.
188 virtual bool UseBackgroundDownloader() const = 0; 184 virtual bool UseBackgroundDownloader() const = 0;
189 }; 185 };
190 186
191 // Start doing update checks and installing new versions of registered 187 // Start doing update checks and installing new versions of registered
192 // components after Configurator::InitialDelay() seconds. 188 // components after Configurator::InitialDelay() seconds.
193 virtual Status Start() = 0; 189 virtual Status Start() = 0;
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 }; 221 };
226 222
227 // Creates the component updater. You must pass a valid |config| allocated on 223 // Creates the component updater. You must pass a valid |config| allocated on
228 // the heap which the component updater will own. 224 // the heap which the component updater will own.
229 ComponentUpdateService* ComponentUpdateServiceFactory( 225 ComponentUpdateService* ComponentUpdateServiceFactory(
230 ComponentUpdateService::Configurator* config); 226 ComponentUpdateService::Configurator* config);
231 227
232 } // namespace component_updater 228 } // namespace component_updater
233 229
234 #endif // CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_ 230 #endif // CHROME_BROWSER_COMPONENT_UPDATER_COMPONENT_UPDATER_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698