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

Side by Side Diff: ios/chrome/browser/payments/payment_request.h

Issue 2972643003: [Payment Request] Records the use of data models used in Payment Request. (Closed)
Patch Set: Addressed comments Created 3 years, 5 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 unified diff | Download patch
« no previous file with comments | « ios/chrome/browser/payments/BUILD.gn ('k') | ios/chrome/browser/payments/payment_request.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_ 5 #ifndef IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_
6 #define IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_ 6 #define IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <set> 10 #include <set>
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 // is one. Returns nullptr otherwise. 197 // is one. Returns nullptr otherwise.
198 web::PaymentShippingOption* selected_shipping_option() const { 198 web::PaymentShippingOption* selected_shipping_option() const {
199 return selected_shipping_option_; 199 return selected_shipping_option_;
200 } 200 }
201 201
202 virtual payments::PaymentsProfileComparator* profile_comparator(); 202 virtual payments::PaymentsProfileComparator* profile_comparator();
203 203
204 // Returns whether the current PaymentRequest can be used to make a payment. 204 // Returns whether the current PaymentRequest can be used to make a payment.
205 bool CanMakePayment() const; 205 bool CanMakePayment() const;
206 206
207 // Record the use of the data models that were used in the Payment Request.
208 void RecordUseStats();
209
207 protected: 210 protected:
208 // Fetches the autofill profiles for this user from the PersonalDataManager, 211 // Fetches the autofill profiles for this user from the PersonalDataManager,
209 // and stores copies of them, owned by this PaymentRequest, in profile_cache_. 212 // and stores copies of them, owned by this PaymentRequest, in profile_cache_.
210 void PopulateProfileCache(); 213 void PopulateProfileCache();
211 214
212 // Sets the available shipping and contact profiles as references to the 215 // Sets the available shipping and contact profiles as references to the
213 // cached profiles ordered by completeness. 216 // cached profiles ordered by completeness.
214 void PopulateAvailableProfiles(); 217 void PopulateAvailableProfiles();
215 218
216 // Fetches the autofill credit cards for this user from the 219 // Fetches the autofill credit cards for this user from the
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 // A vector of pointers to the shipping options in |web_payment_request_|. 291 // A vector of pointers to the shipping options in |web_payment_request_|.
289 std::vector<web::PaymentShippingOption*> shipping_options_; 292 std::vector<web::PaymentShippingOption*> shipping_options_;
290 web::PaymentShippingOption* selected_shipping_option_; 293 web::PaymentShippingOption* selected_shipping_option_;
291 294
292 payments::PaymentsProfileComparator profile_comparator_; 295 payments::PaymentsProfileComparator profile_comparator_;
293 296
294 DISALLOW_COPY_AND_ASSIGN(PaymentRequest); 297 DISALLOW_COPY_AND_ASSIGN(PaymentRequest);
295 }; 298 };
296 299
297 #endif // IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_ 300 #endif // IOS_CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_H_
OLDNEW
« no previous file with comments | « ios/chrome/browser/payments/BUILD.gn ('k') | ios/chrome/browser/payments/payment_request.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698