Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef COMPONENTS_PAYMENTS_CORE_BASIC_CARD_RESPONSE_H_ | |
| 6 #define COMPONENTS_PAYMENTS_CORE_BASIC_CARD_RESPONSE_H_ | |
| 7 | |
| 8 #include <memory> | |
| 9 | |
| 10 #include "base/strings/string16.h" | |
| 11 #include "components/payments/core/payment_address.h" | |
| 12 | |
| 13 namespace base { | |
| 14 class DictionaryValue; | |
| 15 } | |
| 16 | |
| 17 namespace web { | |
| 18 | |
| 19 // Contains the response from the PaymentRequest API when a user accepts | |
| 20 // payment with a Basic Payment Card payment method. | |
| 21 class BasicCardResponse { | |
|
please use gerrit instead
2017/03/08 14:46:09
IMHO, this should be a struct, because it has no p
Mathieu
2017/03/08 18:04:25
Done.
| |
| 22 public: | |
| 23 BasicCardResponse(); | |
| 24 BasicCardResponse(const BasicCardResponse& other); | |
| 25 ~BasicCardResponse(); | |
| 26 | |
| 27 bool operator==(const BasicCardResponse& other) const; | |
| 28 bool operator!=(const BasicCardResponse& other) const; | |
| 29 | |
| 30 // Populates |value| with the properties of this BasicCardResponse. | |
| 31 std::unique_ptr<base::DictionaryValue> ToDictionaryValue() const; | |
| 32 | |
| 33 // The cardholder's name as it appears on the card. | |
| 34 base::string16 cardholder_name; | |
| 35 | |
| 36 // The primary account number (PAN) for the payment card. | |
| 37 base::string16 card_number; | |
| 38 | |
| 39 // A two-digit string for the expiry month of the card in the range 01 to 12. | |
| 40 base::string16 expiry_month; | |
| 41 | |
| 42 // A two-digit string for the expiry year of the card in the range 00 to 99. | |
| 43 base::string16 expiry_year; | |
| 44 | |
| 45 // A three or four digit string for the security code of the card (sometimes | |
| 46 // known as the CVV, CVC, CVN, CVE or CID). | |
| 47 base::string16 card_security_code; | |
| 48 | |
| 49 // The billing address information associated with the payment card. | |
| 50 PaymentAddress billing_address; | |
| 51 }; | |
| 52 | |
| 53 } // namespace web | |
| 54 | |
| 55 #endif // COMPONENTS_PAYMENTS_CORE_BASIC_CARD_RESPONSE_H_ | |
| OLD | NEW |