| OLD | NEW |
| 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 COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ | 5 #ifndef COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ |
| 6 #define COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ | 6 #define COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 AutofillWebDataService* web_data_service); | 53 AutofillWebDataService* web_data_service); |
| 54 | 54 |
| 55 // AutofillWebData implementation. | 55 // AutofillWebData implementation. |
| 56 virtual void AddFormFields( | 56 virtual void AddFormFields( |
| 57 const std::vector<FormFieldData>& fields) OVERRIDE; | 57 const std::vector<FormFieldData>& fields) OVERRIDE; |
| 58 virtual WebDataServiceBase::Handle GetFormValuesForElementName( | 58 virtual WebDataServiceBase::Handle GetFormValuesForElementName( |
| 59 const base::string16& name, | 59 const base::string16& name, |
| 60 const base::string16& prefix, | 60 const base::string16& prefix, |
| 61 int limit, | 61 int limit, |
| 62 WebDataServiceConsumer* consumer) OVERRIDE; | 62 WebDataServiceConsumer* consumer) OVERRIDE; |
| 63 |
| 64 virtual WebDataServiceBase::Handle HasFormElements( |
| 65 WebDataServiceConsumer* consumer) OVERRIDE; |
| 63 virtual void RemoveFormElementsAddedBetween( | 66 virtual void RemoveFormElementsAddedBetween( |
| 64 const base::Time& delete_begin, const base::Time& delete_end) OVERRIDE; | 67 const base::Time& delete_begin, const base::Time& delete_end) OVERRIDE; |
| 65 virtual void RemoveExpiredFormElements() OVERRIDE; | 68 virtual void RemoveExpiredFormElements() OVERRIDE; |
| 66 virtual void RemoveFormValueForElementName( | 69 virtual void RemoveFormValueForElementName( |
| 67 const base::string16& name, | 70 const base::string16& name, |
| 68 const base::string16& value) OVERRIDE; | 71 const base::string16& value) OVERRIDE; |
| 69 virtual void AddAutofillProfile(const AutofillProfile& profile) OVERRIDE; | 72 virtual void AddAutofillProfile(const AutofillProfile& profile) OVERRIDE; |
| 70 virtual void UpdateAutofillProfile(const AutofillProfile& profile) OVERRIDE; | 73 virtual void UpdateAutofillProfile(const AutofillProfile& profile) OVERRIDE; |
| 71 virtual void RemoveAutofillProfile(const std::string& guid) OVERRIDE; | 74 virtual void RemoveAutofillProfile(const std::string& guid) OVERRIDE; |
| 72 virtual WebDataServiceBase::Handle GetAutofillProfiles( | 75 virtual WebDataServiceBase::Handle GetAutofillProfiles( |
| (...skipping 17 matching lines...) Expand all Loading... |
| 90 | 93 |
| 91 // WebDataServiceBase overrides: | 94 // WebDataServiceBase overrides: |
| 92 virtual void NotifyDatabaseLoadedOnUIThread() OVERRIDE; | 95 virtual void NotifyDatabaseLoadedOnUIThread() OVERRIDE; |
| 93 | 96 |
| 94 private: | 97 private: |
| 95 WebDatabase::State AddFormElementsImpl( | 98 WebDatabase::State AddFormElementsImpl( |
| 96 const std::vector<FormFieldData>& fields, WebDatabase* db); | 99 const std::vector<FormFieldData>& fields, WebDatabase* db); |
| 97 scoped_ptr<WDTypedResult> GetFormValuesForElementNameImpl( | 100 scoped_ptr<WDTypedResult> GetFormValuesForElementNameImpl( |
| 98 const base::string16& name, const base::string16& prefix, int limit, | 101 const base::string16& name, const base::string16& prefix, int limit, |
| 99 WebDatabase* db); | 102 WebDatabase* db); |
| 103 scoped_ptr<WDTypedResult> HasFormElementsImpl(WebDatabase* db); |
| 100 WebDatabase::State RemoveFormElementsAddedBetweenImpl( | 104 WebDatabase::State RemoveFormElementsAddedBetweenImpl( |
| 101 const base::Time& delete_begin, const base::Time& delete_end, | 105 const base::Time& delete_begin, const base::Time& delete_end, |
| 102 WebDatabase* db); | 106 WebDatabase* db); |
| 103 WebDatabase::State RemoveExpiredFormElementsImpl(WebDatabase* db); | 107 WebDatabase::State RemoveExpiredFormElementsImpl(WebDatabase* db); |
| 104 WebDatabase::State RemoveFormValueForElementNameImpl( | 108 WebDatabase::State RemoveFormValueForElementNameImpl( |
| 105 const base::string16& name, const base::string16& value, WebDatabase* db); | 109 const base::string16& name, const base::string16& value, WebDatabase* db); |
| 106 WebDatabase::State AddAutofillProfileImpl( | 110 WebDatabase::State AddAutofillProfileImpl( |
| 107 const AutofillProfile& profile, WebDatabase* db); | 111 const AutofillProfile& profile, WebDatabase* db); |
| 108 WebDatabase::State UpdateAutofillProfileImpl( | 112 WebDatabase::State UpdateAutofillProfileImpl( |
| 109 const AutofillProfile& profile, WebDatabase* db); | 113 const AutofillProfile& profile, WebDatabase* db); |
| (...skipping 20 matching lines...) Expand all Loading... |
| 130 | 134 |
| 131 ObserverList<AutofillWebDataServiceObserverOnDBThread> db_observer_list_; | 135 ObserverList<AutofillWebDataServiceObserverOnDBThread> db_observer_list_; |
| 132 ObserverList<AutofillWebDataServiceObserverOnUIThread> ui_observer_list_; | 136 ObserverList<AutofillWebDataServiceObserverOnUIThread> ui_observer_list_; |
| 133 | 137 |
| 134 DISALLOW_COPY_AND_ASSIGN(AutofillWebDataService); | 138 DISALLOW_COPY_AND_ASSIGN(AutofillWebDataService); |
| 135 }; | 139 }; |
| 136 | 140 |
| 137 } // namespace autofill | 141 } // namespace autofill |
| 138 | 142 |
| 139 #endif // COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ | 143 #endif // COMPONENTS_AUTOFILL_BROWSER_WEBDATA_AUTOFILL_WEBDATA_SERVICE_H_ |
| OLD | NEW |