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

Unified Diff: components/safe_browsing_db/v4_local_database_manager.h

Issue 2377273004: Reland: Start checking URLs using PVer4. Verdict not returned to client yet. (Closed)
Patch Set: Remove #DEBUG -- it enables these features on Android :-( Created 4 years, 3 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: components/safe_browsing_db/v4_local_database_manager.h
diff --git a/components/safe_browsing_db/v4_local_database_manager.h b/components/safe_browsing_db/v4_local_database_manager.h
index f9510c4af51fceb49f9b354f6f31c2ab34a57558..c73db1b97164ae41238b5861db9cb214b0ce7bc3 100644
--- a/components/safe_browsing_db/v4_local_database_manager.h
+++ b/components/safe_browsing_db/v4_local_database_manager.h
@@ -28,18 +28,10 @@ typedef unsigned ThreatSeverity;
// SafeBrowsing service and interfaces with the protocol manager.
class V4LocalDatabaseManager : public SafeBrowsingDatabaseManager {
public:
- enum class ClientCallbackType {
- // This represents the case when we're trying to determine if a URL is
- // unsafe from the following perspectives: Malware, Phishing, UwS.
- CHECK_BROWSE_URL = 0,
-
- // This should always be the last value.
- CHECK_MAX
- };
-
- // Construct V4LocalDatabaseManager.
- // Must be initialized by calling StartOnIOThread() before using.
- V4LocalDatabaseManager(const base::FilePath& base_path);
+ // Create and return an instance of V4LocalDatabaseManager, if Finch trial
+ // allows it; nullptr otherwise.
+ static scoped_refptr<V4LocalDatabaseManager> Create(
+ const base::FilePath& base_path);
//
// SafeBrowsingDatabaseManager implementation
@@ -74,6 +66,19 @@ class V4LocalDatabaseManager : public SafeBrowsingDatabaseManager {
//
protected:
+ // Construct V4LocalDatabaseManager.
+ // Must be initialized by calling StartOnIOThread() before using.
+ V4LocalDatabaseManager(const base::FilePath& base_path);
+
+ enum class ClientCallbackType {
+ // This represents the case when we're trying to determine if a URL is
+ // unsafe from the following perspectives: Malware, Phishing, UwS.
+ CHECK_BROWSE_URL = 0,
+
+ // This should always be the last value.
+ CHECK_MAX
+ };
+
// The information we need to process a URL safety reputation request and
// respond to the SafeBrowsing client that asked for it.
// TODO(vakh): In its current form, it only includes information for
« no previous file with comments | « components/safe_browsing_db/v4_feature_list.cc ('k') | components/safe_browsing_db/v4_local_database_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698