Chromium Code Reviews| 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_COMMON_PASSWORD_FORM_H__ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_COMMON_PASSWORD_FORM_H__ |
| 6 #define COMPONENTS_AUTOFILL_CORE_COMMON_PASSWORD_FORM_H__ | 6 #define COMPONENTS_AUTOFILL_CORE_COMMON_PASSWORD_FORM_H__ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 199 // Default to false. | 199 // Default to false. |
| 200 bool use_additional_authentication; | 200 bool use_additional_authentication; |
| 201 | 201 |
| 202 // Autofill representation of this form. Used to communicate with the | 202 // Autofill representation of this form. Used to communicate with the |
| 203 // Autofill servers if necessary. Currently this is only used to help | 203 // Autofill servers if necessary. Currently this is only used to help |
| 204 // determine forms where we can trigger password generation. | 204 // determine forms where we can trigger password generation. |
| 205 // | 205 // |
| 206 // When parsing an HTML form, this is normally set. | 206 // When parsing an HTML form, this is normally set. |
| 207 FormData form_data; | 207 FormData form_data; |
| 208 | 208 |
| 209 // User friendly name to show in the UI. | |
|
Garrett Casto
2014/08/21 22:13:41
Can you put a comment here talking about how these
vasilii
2014/08/22 09:03:33
Done.
| |
| 210 base::string16 display_name; | |
| 211 | |
| 212 // The URL of the user's avatar to display in the UI. | |
| 213 GURL avatar_url; | |
| 214 | |
| 215 // The URL of identity provider used for federated login. | |
| 216 GURL federation_url; | |
| 217 | |
| 218 // If true, Chrome will sign the user in automatically using the credentials. | |
| 219 bool is_zero_click; | |
| 220 | |
| 209 // Returns true if this match was found using public suffix matching. | 221 // Returns true if this match was found using public suffix matching. |
| 210 bool IsPublicSuffixMatch() const; | 222 bool IsPublicSuffixMatch() const; |
| 211 | 223 |
| 212 // Equality operators for testing. | 224 // Equality operators for testing. |
| 213 bool operator==(const PasswordForm& form) const; | 225 bool operator==(const PasswordForm& form) const; |
| 214 bool operator!=(const PasswordForm& form) const; | 226 bool operator!=(const PasswordForm& form) const; |
| 215 | 227 |
| 216 PasswordForm(); | 228 PasswordForm(); |
| 217 ~PasswordForm(); | 229 ~PasswordForm(); |
| 218 }; | 230 }; |
| 219 | 231 |
| 220 // Map username to PasswordForm* for convenience. See password_form_manager.h. | 232 // Map username to PasswordForm* for convenience. See password_form_manager.h. |
| 221 typedef std::map<base::string16, PasswordForm*> PasswordFormMap; | 233 typedef std::map<base::string16, PasswordForm*> PasswordFormMap; |
| 222 | 234 |
| 223 typedef std::map<base::string16, const PasswordForm*> ConstPasswordFormMap; | 235 typedef std::map<base::string16, const PasswordForm*> ConstPasswordFormMap; |
| 224 | 236 |
| 225 // For testing. | 237 // For testing. |
| 226 std::ostream& operator<<(std::ostream& os, | 238 std::ostream& operator<<(std::ostream& os, |
| 227 const autofill::PasswordForm& form); | 239 const autofill::PasswordForm& form); |
| 228 | 240 |
| 229 } // namespace autofill | 241 } // namespace autofill |
| 230 | 242 |
| 231 #endif // COMPONENTS_AUTOFILL_CORE_COMMON_PASSWORD_FORM_H__ | 243 #endif // COMPONENTS_AUTOFILL_CORE_COMMON_PASSWORD_FORM_H__ |
| OLD | NEW |