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

Side by Side Diff: chrome/browser/component_updater/component_updater_configurator.cc

Issue 25883006: Support asynchronous patching operations in the component updater. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@tests
Patch Set: sorin@, cpu@ review Created 7 years 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #include "chrome/browser/component_updater/component_updater_configurator.h" 5 #include "chrome/browser/component_updater/component_updater_configurator.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 virtual int StepDelay() OVERRIDE; 97 virtual int StepDelay() OVERRIDE;
98 virtual int StepDelayMedium() OVERRIDE; 98 virtual int StepDelayMedium() OVERRIDE;
99 virtual int MinimumReCheckWait() OVERRIDE; 99 virtual int MinimumReCheckWait() OVERRIDE;
100 virtual int OnDemandDelay() OVERRIDE; 100 virtual int OnDemandDelay() OVERRIDE;
101 virtual GURL UpdateUrl() OVERRIDE; 101 virtual GURL UpdateUrl() OVERRIDE;
102 virtual GURL PingUrl() OVERRIDE; 102 virtual GURL PingUrl() OVERRIDE;
103 virtual const char* ExtraRequestParams() OVERRIDE; 103 virtual const char* ExtraRequestParams() OVERRIDE;
104 virtual size_t UrlSizeLimit() OVERRIDE; 104 virtual size_t UrlSizeLimit() OVERRIDE;
105 virtual net::URLRequestContextGetter* RequestContext() OVERRIDE; 105 virtual net::URLRequestContextGetter* RequestContext() OVERRIDE;
106 virtual bool InProcess() OVERRIDE; 106 virtual bool InProcess() OVERRIDE;
107 virtual ComponentPatcher* CreateComponentPatcher() OVERRIDE; 107 virtual component_updater::ComponentPatcher*
108 CreateComponentPatcher() OVERRIDE;
108 virtual bool DeltasEnabled() const OVERRIDE; 109 virtual bool DeltasEnabled() const OVERRIDE;
109 110
110 private: 111 private:
111 net::URLRequestContextGetter* url_request_getter_; 112 net::URLRequestContextGetter* url_request_getter_;
112 std::string extra_info_; 113 std::string extra_info_;
113 std::string url_source_; 114 std::string url_source_;
114 bool fast_update_; 115 bool fast_update_;
115 bool pings_enabled_; 116 bool pings_enabled_;
116 bool deltas_enabled_; 117 bool deltas_enabled_;
117 }; 118 };
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 } 194 }
194 195
195 net::URLRequestContextGetter* ChromeConfigurator::RequestContext() { 196 net::URLRequestContextGetter* ChromeConfigurator::RequestContext() {
196 return url_request_getter_; 197 return url_request_getter_;
197 } 198 }
198 199
199 bool ChromeConfigurator::InProcess() { 200 bool ChromeConfigurator::InProcess() {
200 return false; 201 return false;
201 } 202 }
202 203
203 ComponentPatcher* ChromeConfigurator::CreateComponentPatcher() { 204 component_updater::ComponentPatcher*
205 ChromeConfigurator::CreateComponentPatcher() {
204 #if defined(OS_WIN) 206 #if defined(OS_WIN)
205 return new ComponentPatcherWin(); 207 return new ComponentPatcherWin();
206 #else 208 #else
207 return new ComponentPatcherCrossPlatform(); 209 return new component_updater::ComponentPatcherCrossPlatform();
208 #endif 210 #endif
209 } 211 }
210 212
211 bool ChromeConfigurator::DeltasEnabled() const { 213 bool ChromeConfigurator::DeltasEnabled() const {
212 return deltas_enabled_; 214 return deltas_enabled_;
213 } 215 }
214 216
215 ComponentUpdateService::Configurator* MakeChromeComponentUpdaterConfigurator( 217 ComponentUpdateService::Configurator* MakeChromeComponentUpdaterConfigurator(
216 const CommandLine* cmdline, net::URLRequestContextGetter* context_getter) { 218 const CommandLine* cmdline, net::URLRequestContextGetter* context_getter) {
217 return new ChromeConfigurator(cmdline, context_getter); 219 return new ChromeConfigurator(cmdline, context_getter);
218 } 220 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698