OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ |
6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ |
7 | 7 |
8 #include "sync/internal_api/public/base/model_type.h" | |
9 | |
8 class WebDatabase; | 10 class WebDatabase; |
9 | 11 |
10 namespace autofill { | 12 namespace autofill { |
11 | 13 |
12 class AutofillWebDataServiceObserverOnDBThread; | 14 class AutofillWebDataServiceObserverOnDBThread; |
13 | 15 |
14 // Interface for doing Autofill work directly on the DB thread (used by | 16 // Interface for doing Autofill work directly on the DB thread (used by |
15 // Sync, mostly), without fully exposing the AutofillWebDataBackend to clients. | 17 // Sync, mostly), without fully exposing the AutofillWebDataBackend to clients. |
16 class AutofillWebDataBackend { | 18 class AutofillWebDataBackend { |
17 public: | 19 public: |
(...skipping 11 matching lines...) Expand all Loading... | |
29 AutofillWebDataServiceObserverOnDBThread* observer) = 0; | 31 AutofillWebDataServiceObserverOnDBThread* observer) = 0; |
30 | 32 |
31 // Remove expired elements from the database and commit if needed. | 33 // Remove expired elements from the database and commit if needed. |
32 virtual void RemoveExpiredFormElements() = 0; | 34 virtual void RemoveExpiredFormElements() = 0; |
33 | 35 |
34 // Notifies listeners on both DB and UI threads that multiple changes have | 36 // Notifies listeners on both DB and UI threads that multiple changes have |
35 // been made to to Autofill records of the database. | 37 // been made to to Autofill records of the database. |
36 // NOTE: This method is intended to be called from the DB thread. The UI | 38 // NOTE: This method is intended to be called from the DB thread. The UI |
37 // thread notifications are asynchronous. | 39 // thread notifications are asynchronous. |
38 virtual void NotifyOfMultipleAutofillChanges() = 0; | 40 virtual void NotifyOfMultipleAutofillChanges() = 0; |
41 | |
42 // Notifies listeners on both DB and UI threads that sync has started for | |
Mathieu
2016/07/18 14:53:19
Not sure I see how DB thread observers are notifie
Roger McFarlane (Chromium)
2016/07/18 15:29:18
Copy-paste error, fixed.
| |
43 // |model_type|. | |
44 virtual void NotifyThatSyncHasStarted(syncer::ModelType model_type) = 0; | |
39 }; | 45 }; |
40 | 46 |
41 } // namespace autofill | 47 } // namespace autofill |
42 | 48 |
43 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ | 49 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_WEBDATA_AUTOFILL_WEBDATA_BACKEND_H_ |
OLD | NEW |