| 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_PERSONAL_DATA_MANAGER_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_PERSONAL_DATA_MANAGER_H_ |
| 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_PERSONAL_DATA_MANAGER_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_PERSONAL_DATA_MANAGER_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 // Deletes all server profiles and cards (both masked and unmasked). | 177 // Deletes all server profiles and cards (both masked and unmasked). |
| 178 void ClearAllServerData(); | 178 void ClearAllServerData(); |
| 179 | 179 |
| 180 // Sets a server credit card for test. | 180 // Sets a server credit card for test. |
| 181 void AddServerCreditCardForTest(std::unique_ptr<CreditCard> credit_card); | 181 void AddServerCreditCardForTest(std::unique_ptr<CreditCard> credit_card); |
| 182 | 182 |
| 183 // Returns the credit card with the specified |guid|, or nullptr if there is | 183 // Returns the credit card with the specified |guid|, or nullptr if there is |
| 184 // no credit card with the specified |guid|. | 184 // no credit card with the specified |guid|. |
| 185 virtual CreditCard* GetCreditCardByGUID(const std::string& guid); | 185 virtual CreditCard* GetCreditCardByGUID(const std::string& guid); |
| 186 | 186 |
| 187 // Returns the credit card with the specified |number|, or nullptr if there is |
| 188 // no credit card with the specified |number|. |
| 189 virtual CreditCard* GetCreditCardByNumber(const std::string& number); |
| 190 |
| 187 // Gets the field types availabe in the stored address and credit card data. | 191 // Gets the field types availabe in the stored address and credit card data. |
| 188 void GetNonEmptyTypes(ServerFieldTypeSet* non_empty_types); | 192 void GetNonEmptyTypes(ServerFieldTypeSet* non_empty_types); |
| 189 | 193 |
| 190 // Returns true if the credit card information is stored with a password. | 194 // Returns true if the credit card information is stored with a password. |
| 191 bool HasPassword(); | 195 bool HasPassword(); |
| 192 | 196 |
| 193 // Returns whether the personal data has been loaded from the web database. | 197 // Returns whether the personal data has been loaded from the web database. |
| 194 virtual bool IsDataLoaded() const; | 198 virtual bool IsDataLoaded() const; |
| 195 | 199 |
| 196 // This PersonalDataManager owns these profiles and credit cards. Their | 200 // This PersonalDataManager owns these profiles and credit cards. Their |
| (...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 614 // The context for the request to be used to fetch libaddressinput's address | 618 // The context for the request to be used to fetch libaddressinput's address |
| 615 // validation rules. | 619 // validation rules. |
| 616 scoped_refptr<net::URLRequestContextGetter> context_getter_; | 620 scoped_refptr<net::URLRequestContextGetter> context_getter_; |
| 617 | 621 |
| 618 DISALLOW_COPY_AND_ASSIGN(PersonalDataManager); | 622 DISALLOW_COPY_AND_ASSIGN(PersonalDataManager); |
| 619 }; | 623 }; |
| 620 | 624 |
| 621 } // namespace autofill | 625 } // namespace autofill |
| 622 | 626 |
| 623 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_PERSONAL_DATA_MANAGER_H_ | 627 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_PERSONAL_DATA_MANAGER_H_ |
| OLD | NEW |