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

Side by Side Diff: chrome/browser/safe_browsing/safe_browsing_service.h

Issue 657373004: Standardize usage of virtual/override/final in chrome/browser/safe_browsing/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 (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 // The Safe Browsing service is responsible for downloading anti-phishing and 5 // The Safe Browsing service is responsible for downloading anti-phishing and
6 // anti-malware tables and checking urls against them. 6 // anti-malware tables and checking urls against them.
7 7
8 #ifndef CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 8 #ifndef CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
9 #define CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 9 #define CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
10 10
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 // Registers |callback| to be run after some delay following process launch. 128 // Registers |callback| to be run after some delay following process launch.
129 // |callback| will be dropped if the service is not applicable for the 129 // |callback| will be dropped if the service is not applicable for the
130 // process. 130 // process.
131 void RegisterDelayedAnalysisCallback( 131 void RegisterDelayedAnalysisCallback(
132 const safe_browsing::DelayedAnalysisCallback& callback); 132 const safe_browsing::DelayedAnalysisCallback& callback);
133 133
134 protected: 134 protected:
135 // Creates the safe browsing service. Need to initialize before using. 135 // Creates the safe browsing service. Need to initialize before using.
136 SafeBrowsingService(); 136 SafeBrowsingService();
137 137
138 virtual ~SafeBrowsingService(); 138 ~SafeBrowsingService() override;
139 139
140 virtual SafeBrowsingDatabaseManager* CreateDatabaseManager(); 140 virtual SafeBrowsingDatabaseManager* CreateDatabaseManager();
141 141
142 virtual SafeBrowsingUIManager* CreateUIManager(); 142 virtual SafeBrowsingUIManager* CreateUIManager();
143 143
144 // Registers all the delayed analysis with the incident reporting service. 144 // Registers all the delayed analysis with the incident reporting service.
145 // This is where you register your process-wide, profile-independent analysis. 145 // This is where you register your process-wide, profile-independent analysis.
146 virtual void RegisterAllDelayedAnalysis(); 146 virtual void RegisterAllDelayedAnalysis();
147 147
148 private: 148 private:
(...skipping 25 matching lines...) Expand all
174 // the user checks the "Enable SafeBrowsing" option in the Advanced options 174 // the user checks the "Enable SafeBrowsing" option in the Advanced options
175 // UI. 175 // UI.
176 void Start(); 176 void Start();
177 177
178 // Stops the SafeBrowsingService. This can be called when the safe browsing 178 // Stops the SafeBrowsingService. This can be called when the safe browsing
179 // preference is disabled. When shutdown is true, operation is permanently 179 // preference is disabled. When shutdown is true, operation is permanently
180 // shutdown and cannot be restarted. 180 // shutdown and cannot be restarted.
181 void Stop(bool shutdown); 181 void Stop(bool shutdown);
182 182
183 // content::NotificationObserver override 183 // content::NotificationObserver override
184 virtual void Observe(int type, 184 void Observe(int type,
185 const content::NotificationSource& source, 185 const content::NotificationSource& source,
186 const content::NotificationDetails& details) override; 186 const content::NotificationDetails& details) override;
187 187
188 // Starts following the safe browsing preference on |pref_service|. 188 // Starts following the safe browsing preference on |pref_service|.
189 void AddPrefService(PrefService* pref_service); 189 void AddPrefService(PrefService* pref_service);
190 190
191 // Stop following the safe browsing preference on |pref_service|. 191 // Stop following the safe browsing preference on |pref_service|.
192 void RemovePrefService(PrefService* pref_service); 192 void RemovePrefService(PrefService* pref_service);
193 193
194 // Checks if any profile is currently using the safe browsing service, and 194 // Checks if any profile is currently using the safe browsing service, and
195 // starts or stops the service accordingly. 195 // starts or stops the service accordingly.
196 void RefreshState(); 196 void RefreshState();
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 class SafeBrowsingServiceFactory { 254 class SafeBrowsingServiceFactory {
255 public: 255 public:
256 SafeBrowsingServiceFactory() { } 256 SafeBrowsingServiceFactory() { }
257 virtual ~SafeBrowsingServiceFactory() { } 257 virtual ~SafeBrowsingServiceFactory() { }
258 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0; 258 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0;
259 private: 259 private:
260 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory); 260 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory);
261 }; 261 };
262 262
263 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 263 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/safe_browsing_database.cc ('k') | chrome/browser/safe_browsing/safe_browsing_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698