OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_AUTOFILL_PERSONAL_DATA_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_AUTOFILL_PERSONAL_DATA_MANAGER_H_ |
6 #define CHROME_BROWSER_AUTOFILL_PERSONAL_DATA_MANAGER_H_ | 6 #define CHROME_BROWSER_AUTOFILL_PERSONAL_DATA_MANAGER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 #include <vector> | 10 #include <vector> |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 // result. | 134 // result. |
135 static bool MergeProfile( | 135 static bool MergeProfile( |
136 const AutofillProfile& profile, | 136 const AutofillProfile& profile, |
137 const std::vector<AutofillProfile*>& existing_profiles, | 137 const std::vector<AutofillProfile*>& existing_profiles, |
138 std::vector<AutofillProfile>* merged_profiles); | 138 std::vector<AutofillProfile>* merged_profiles); |
139 | 139 |
140 protected: | 140 protected: |
141 // Make sure that only Profile and certain tests can create an instance of | 141 // Make sure that only Profile and certain tests can create an instance of |
142 // PersonalDataManager. | 142 // PersonalDataManager. |
143 friend class base::RefCountedThreadSafe<PersonalDataManager>; | 143 friend class base::RefCountedThreadSafe<PersonalDataManager>; |
| 144 friend class AutofillHelper; |
144 friend class AutofillMergeTest; | 145 friend class AutofillMergeTest; |
145 friend class LiveAutofillSyncTest; | |
146 friend class PersonalDataManagerTest; | 146 friend class PersonalDataManagerTest; |
147 friend class ProfileImpl; | 147 friend class ProfileImpl; |
148 friend class ProfileSyncServiceAutofillTest; | 148 friend class ProfileSyncServiceAutofillTest; |
149 friend class TestingAutomationProvider; | 149 friend class TestingAutomationProvider; |
150 | 150 |
151 PersonalDataManager(); | 151 PersonalDataManager(); |
152 virtual ~PersonalDataManager(); | 152 virtual ~PersonalDataManager(); |
153 | 153 |
154 // Sets |web_profiles_| to the contents of |profiles| and updates the web | 154 // Sets |web_profiles_| to the contents of |profiles| and updates the web |
155 // database by adding, updating and removing profiles. | 155 // database by adding, updating and removing profiles. |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
240 // For logging UMA metrics. Overridden by metrics tests. | 240 // For logging UMA metrics. Overridden by metrics tests. |
241 scoped_ptr<const AutofillMetrics> metric_logger_; | 241 scoped_ptr<const AutofillMetrics> metric_logger_; |
242 | 242 |
243 // Whether we have already logged the number of profiles this session. | 243 // Whether we have already logged the number of profiles this session. |
244 mutable bool has_logged_profile_count_; | 244 mutable bool has_logged_profile_count_; |
245 | 245 |
246 DISALLOW_COPY_AND_ASSIGN(PersonalDataManager); | 246 DISALLOW_COPY_AND_ASSIGN(PersonalDataManager); |
247 }; | 247 }; |
248 | 248 |
249 #endif // CHROME_BROWSER_AUTOFILL_PERSONAL_DATA_MANAGER_H_ | 249 #endif // CHROME_BROWSER_AUTOFILL_PERSONAL_DATA_MANAGER_H_ |
OLD | NEW |