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

Unified Diff: chrome/browser/safe_browsing/services_delegate_impl.h

Issue 1924983002: Enable V4LocalDatabaseManager based on Finch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor. CR feedback. Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/safe_browsing/services_delegate_impl.h
diff --git a/chrome/browser/safe_browsing/services_delegate_impl.h b/chrome/browser/safe_browsing/services_delegate_impl.h
index 19e024b4067c8f3c89350e1ecad49214cbccd9f1..e861d25a07e70245d6675d8cf7640bcfc8da8ef0 100644
--- a/chrome/browser/safe_browsing/services_delegate_impl.h
+++ b/chrome/browser/safe_browsing/services_delegate_impl.h
@@ -16,6 +16,8 @@
namespace safe_browsing {
+class V4LocalDatabaseManager;
+
// Actual ServicesDelegate implementation. Create via
// ServicesDelegate::Create().
class ServicesDelegateImpl : public ServicesDelegate {
@@ -26,9 +28,9 @@ class ServicesDelegateImpl : public ServicesDelegate {
private:
// ServicesDelegate:
+ void Initialize() override;
void InitializeCsdService(
net::URLRequestContextGetter* context_getter) override;
- void InitializeServices() override;
void ShutdownServices() override;
void RefreshState(bool enable) override;
void ProcessResourceRequest(const ResourceRequestInfo* request) override;
@@ -42,6 +44,16 @@ class ServicesDelegateImpl : public ServicesDelegate {
ClientSideDetectionService* GetCsdService() override;
DownloadProtectionService* GetDownloadService() override;
+ void StartOnIOThread(
+ net::URLRequestContextGetter* url_request_context_getter,
+ const V4ProtocolConfig& v4_config) override;
+ void StopOnIOThread(bool shutdown) override;
+
+ // Is the Pver4 database manager enabled? Controlled by Finch.
+ bool IsV4LocalDatabaseManagerEnabled();
+
+ V4LocalDatabaseManager* CreateV4LocalDatabaseManager();
+
DownloadProtectionService* CreateDownloadProtectionService();
IncidentReportingService* CreateIncidentReportingService();
ResourceRequestDetector* CreateResourceRequestDetector();
@@ -54,6 +66,10 @@ class ServicesDelegateImpl : public ServicesDelegate {
SafeBrowsingService* const safe_browsing_service_;
ServicesDelegate::ServicesCreator* const services_creator_;
+ // The Pver4 local database manager handles the database and download logic
+ // Accessed on both UI and IO thread.
+ scoped_refptr<V4LocalDatabaseManager> v4_local_database_manager_;
+
DISALLOW_COPY_AND_ASSIGN(ServicesDelegateImpl);
};

Powered by Google App Engine
This is Rietveld 408576698