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

Unified Diff: ios/web/public/payments/payment_request.h

Issue 2797633002: [Payments] Move PaymentMethodData to components/payments/core (Closed)
Patch Set: clean Created 3 years, 8 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
« no previous file with comments | « ios/web/payments/payment_request_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/public/payments/payment_request.h
diff --git a/ios/web/public/payments/payment_request.h b/ios/web/public/payments/payment_request.h
index 0fec12d61971f95bb11830ee3685ae87d65d487d..a2e9d5e1ee2482f66f68e9dfb212ba93a1773cb1 100644
--- a/ios/web/public/payments/payment_request.h
+++ b/ios/web/public/payments/payment_request.h
@@ -11,6 +11,7 @@
#include "base/strings/string16.h"
#include "components/payments/core/basic_card_response.h"
#include "components/payments/core/payment_address.h"
+#include "components/payments/core/payment_method_data.h"
// C++ bindings for the PaymentRequest API. Conforms to the following specs:
// https://w3c.github.io/browser-payment-api/ (18 July 2016 editor's draft)
@@ -22,30 +23,6 @@ class DictionaryValue;
namespace web {
-// A set of supported payment methods and any associated payment method specific
-// data for those methods.
-class PaymentMethodData {
- public:
- PaymentMethodData();
- PaymentMethodData(const PaymentMethodData& other);
- ~PaymentMethodData();
-
- bool operator==(const PaymentMethodData& other) const;
- bool operator!=(const PaymentMethodData& other) const;
-
- // Populates the properties of this PaymentMethodData from |value|. Returns
- // true if the required values are present.
- bool FromDictionaryValue(const base::DictionaryValue& value);
-
- // Payment method identifiers for payment methods that the merchant web site
- // accepts.
- std::vector<base::string16> supported_methods;
-
- // A JSON-serialized object that provides optional information that might be
- // needed by the supported payment methods.
- base::string16 data;
-};
-
// Supplies monetary amounts.
class PaymentCurrencyAmount {
public:
@@ -266,7 +243,7 @@ class PaymentRequest {
// Properties set via the constructor for communicating from the page to the
// browser UI.
- std::vector<PaymentMethodData> method_data;
+ std::vector<payments::PaymentMethodData> method_data;
PaymentDetails details;
PaymentOptions options;
};
« no previous file with comments | « ios/web/payments/payment_request_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698