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_BROWSER_AUTOFILL_METRICS_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_METRICS_H_ |
| 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_METRICS_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_METRICS_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 100 // prompt. | 100 // prompt. |
| 101 UPLOAD_OFFERED = 1 << 0, | 101 UPLOAD_OFFERED = 1 << 0, |
| 102 // CVC field was not found in the form. | 102 // CVC field was not found in the form. |
| 103 CVC_FIELD_NOT_FOUND = 1 << 1, | 103 CVC_FIELD_NOT_FOUND = 1 << 1, |
| 104 // CVC field was found, but field did not have a value. | 104 // CVC field was found, but field did not have a value. |
| 105 CVC_VALUE_NOT_FOUND = 1 << 2, | 105 CVC_VALUE_NOT_FOUND = 1 << 2, |
| 106 // CVC field had a value, but it was not valid for the card network. | 106 // CVC field had a value, but it was not valid for the card network. |
| 107 INVALID_CVC_VALUE = 1 << 3, | 107 INVALID_CVC_VALUE = 1 << 3, |
| 108 // A CVC was detected but no recently created or used address was available. | 108 // A CVC was detected but no recently created or used address was available. |
| 109 // We don't know whether we would have been able to get upload details. | 109 // We don't know whether we would have been able to get upload details. |
| 110 UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 << 4, | 110 UPLOAD_NOT_OFFERED_NO_RECENTLY_USED_ADDRESS = 1 << 4, |
| 111 // A CVC was detected but no address was available. | |
|
Jared Saul
2017/05/05 22:17:50
"A CVC was detected but..." isn't strictly true be
csashi
2017/05/05 22:42:27
Done.
| |
| 112 // We don't know whether we would have been able to get upload details. | |
| 113 UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 << 5, | |
| 111 // A CVC and one or more addresses were available but no name was found on | 114 // A CVC and one or more addresses were available but no name was found on |
| 112 // either the card or the address(es). We don't know whether the address(es) | 115 // either the card or the address(es). We don't know whether the address(es) |
| 113 // were otherwise valid nor whether we would have been able to get upload | 116 // were otherwise valid nor whether we would have been able to get upload |
| 114 // details. | 117 // details. |
| 115 UPLOAD_NOT_OFFERED_NO_NAME = 1 << 5, | 118 UPLOAD_NOT_OFFERED_NO_NAME = 1 << 6, |
| 116 // A CVC, multiple addresses, and a name were available but the addresses | 119 // A CVC, multiple addresses, and a name were available but the addresses |
| 117 // had | 120 // had |
| 118 // conflicting zip codes. We don't know whether we would have been able to | 121 // conflicting zip codes. We don't know whether we would have been able to |
| 119 // get upload details. | 122 // get upload details. |
| 120 UPLOAD_NOT_OFFERED_CONFLICTING_ZIPS = 1 << 6, | 123 UPLOAD_NOT_OFFERED_CONFLICTING_ZIPS = 1 << 7, |
| 121 // A CVC, one or more addresses, and a name were available but no zip code | 124 // A CVC, one or more addresses, and a name were available but no zip code |
| 122 // was found on any of the address(es). We don't know whether we would have | 125 // was found on any of the address(es). We don't know whether we would have |
| 123 // been able to get upload details. | 126 // been able to get upload details. |
| 124 UPLOAD_NOT_OFFERED_NO_ZIP_CODE = 1 << 7, | 127 UPLOAD_NOT_OFFERED_NO_ZIP_CODE = 1 << 8, |
| 125 // A CVC and one or more addresses were available but the names on the card | 128 // A CVC and one or more addresses were available but the names on the card |
| 126 // and/or the addresses didn't match. We don't know whether the address(es) | 129 // and/or the addresses didn't match. We don't know whether the address(es) |
| 127 // were otherwise valid nor whether we would have been able to get upload | 130 // were otherwise valid nor whether we would have been able to get upload |
| 128 // details. | 131 // details. |
| 129 UPLOAD_NOT_OFFERED_CONFLICTING_NAMES = 1 << 8, | 132 UPLOAD_NOT_OFFERED_CONFLICTING_NAMES = 1 << 9, |
| 130 // A CVC, one or more valid addresses, and a name were available but the | 133 // A CVC, one or more valid addresses, and a name were available but the |
| 131 // request to Payments for upload details failed. | 134 // request to Payments for upload details failed. |
| 132 UPLOAD_NOT_OFFERED_GET_UPLOAD_DETAILS_FAILED = 1 << 9, | 135 UPLOAD_NOT_OFFERED_GET_UPLOAD_DETAILS_FAILED = 1 << 10, |
| 133 // Update |kNumCardUploadDecisionMetrics| when adding new enum here. | 136 // Update |kNumCardUploadDecisionMetrics| when adding new enum here. |
| 134 }; | 137 }; |
| 135 | 138 |
| 136 enum DeveloperEngagementMetric { | 139 enum DeveloperEngagementMetric { |
| 137 // Parsed a form that is potentially autofillable and does not contain any | 140 // Parsed a form that is potentially autofillable and does not contain any |
| 138 // web developer-specified field type hint. | 141 // web developer-specified field type hint. |
| 139 FILLABLE_FORM_PARSED_WITHOUT_TYPE_HINTS = 0, | 142 FILLABLE_FORM_PARSED_WITHOUT_TYPE_HINTS = 0, |
| 140 // Parsed a form that is potentially autofillable and contains at least one | 143 // Parsed a form that is potentially autofillable and contains at least one |
| 141 // web developer-specified field type hint, a la | 144 // web developer-specified field type hint, a la |
| 142 // http://is.gd/whatwg_autocomplete | 145 // http://is.gd/whatwg_autocomplete |
| (...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 881 bool logged_suggestion_filled_was_masked_server_card_; | 884 bool logged_suggestion_filled_was_masked_server_card_; |
| 882 | 885 |
| 883 // The last field that was polled for suggestions. | 886 // The last field that was polled for suggestions. |
| 884 FormFieldData last_polled_field_; | 887 FormFieldData last_polled_field_; |
| 885 | 888 |
| 886 FormInteractionsUkmLogger* | 889 FormInteractionsUkmLogger* |
| 887 form_interactions_ukm_logger_; // Weak reference. | 890 form_interactions_ukm_logger_; // Weak reference. |
| 888 }; | 891 }; |
| 889 | 892 |
| 890 private: | 893 private: |
| 891 static const int kNumCardUploadDecisionMetrics = 10; | 894 static const int kNumCardUploadDecisionMetrics = 11; |
| 892 | 895 |
| 893 DISALLOW_IMPLICIT_CONSTRUCTORS(AutofillMetrics); | 896 DISALLOW_IMPLICIT_CONSTRUCTORS(AutofillMetrics); |
| 894 }; | 897 }; |
| 895 | 898 |
| 896 } // namespace autofill | 899 } // namespace autofill |
| 897 | 900 |
| 898 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_METRICS_H_ | 901 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_AUTOFILL_METRICS_H_ |
| OLD | NEW |