Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1210)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java

Issue 2447953002: [Payments] Add metrics for the new payer name contact info. (Closed)
Patch Set: Nits Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java
index de2ece255fb70579f2956516f657b1a628794a17..2cf087ed23fee3dc8b689108d6cf3402ba66031a 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestMetrics.java
@@ -22,7 +22,9 @@ public final class PaymentRequestMetrics {
@VisibleForTesting
public static final int REQUESTED_INFORMATION_SHIPPING = 1 << 2;
@VisibleForTesting
- public static final int REQUESTED_INFORMATION_MAX = 8;
+ public static final int REQUESTED_INFORMATION_NAME = 1 << 3;
+ @VisibleForTesting
+ public static final int REQUESTED_INFORMATION_MAX = 16;
// PaymentRequestAbortReason defined in tools/metrics/histograms/histograms.xml.
@VisibleForTesting
@@ -63,16 +65,18 @@ public final class PaymentRequestMetrics {
* Records the metric that keeps track of what user information are requested by merchants to
* complete a payment request.
*
- * @param requestEmail Whether the merchant requested an email address.
- * @param requestPhone Whether the merchant requested a phone number.
+ * @param requestEmail Whether the merchant requested an email address.
+ * @param requestPhone Whether the merchant requested a phone number.
* @param requestShipping Whether the merchant requested a shipping address.
+ * @param requestName Whether the merchant requestes a name.
*/
public static void recordRequestedInformationHistogram(boolean requestEmail,
- boolean requestPhone, boolean requestShipping) {
+ boolean requestPhone, boolean requestShipping, boolean requestName) {
int requestInformation =
(requestEmail ? REQUESTED_INFORMATION_EMAIL : 0)
| (requestPhone ? REQUESTED_INFORMATION_PHONE : 0)
- | (requestShipping ? REQUESTED_INFORMATION_SHIPPING : 0);
+ | (requestShipping ? REQUESTED_INFORMATION_SHIPPING : 0)
+ | (requestName ? REQUESTED_INFORMATION_NAME : 0);
RecordHistogram.recordEnumeratedHistogram("PaymentRequest.RequestedInformation",
requestInformation, REQUESTED_INFORMATION_MAX);
}
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java ('k') | chrome/android/java_sources.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698