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

Side by Side Diff: chrome/browser/api/webdata/web_data_service_base.h

Issue 10919066: Use BrowserContext as key in API. Switch Autofill to use BC in place of Profile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
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 #ifndef CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_ 5 #ifndef CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_
6 #define CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_ 6 #define CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_
7 7
8 #include "chrome/browser/profiles/refcounted_profile_keyed_service.h" 8 #include "chrome/browser/profiles/refcounted_profile_keyed_service.h"
9 9
10 class Profile; 10 namespace content {
11 class BrowserContext;
12 }
11 13
12 // Base for WebDataService class hierarchy. 14 // Base for WebDataService class hierarchy.
13 class WebDataServiceBase : public RefcountedProfileKeyedService { 15 class WebDataServiceBase : public RefcountedProfileKeyedService {
14 public: 16 public:
15 static scoped_refptr<WebDataServiceBase> ForProfile(Profile* profile); 17 static scoped_refptr<WebDataServiceBase> ForContext(
18 content::BrowserContext* profile);
16 19
17 // All requests return an opaque handle of the following type. 20 // All requests return an opaque handle of the following type.
18 typedef int Handle; 21 typedef int Handle;
19 22
20 WebDataServiceBase(); 23 WebDataServiceBase();
21 24
22 // Cancel any pending request. You need to call this method if your 25 // Cancel any pending request. You need to call this method if your
23 // WebDataServiceConsumer is about to be deleted. 26 // WebDataServiceConsumer is about to be deleted.
24 virtual void CancelRequest(Handle h) = 0; 27 virtual void CancelRequest(Handle h) = 0;
25 28
26 protected: 29 protected:
27 virtual ~WebDataServiceBase() {} 30 virtual ~WebDataServiceBase() {}
28 }; 31 };
29 32
30 #endif // CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_ 33 #endif // CHROME_BROWSER_API_WEBDATA_WEB_DATA_SERVICE_BASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698