OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 package org.chromium.chrome.browser.payments; | 5 package org.chromium.chrome.browser.payments; |
6 | 6 |
7 import android.graphics.drawable.Drawable; | 7 import android.graphics.drawable.Drawable; |
8 | 8 |
9 import org.chromium.chrome.browser.payments.ui.PaymentOption; | 9 import org.chromium.chrome.browser.payments.ui.PaymentOption; |
10 import org.chromium.payments.mojom.PaymentDetailsModifier; | 10 import org.chromium.payments.mojom.PaymentDetailsModifier; |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 * | 66 * |
67 * @return The method names for this instrument. | 67 * @return The method names for this instrument. |
68 */ | 68 */ |
69 public abstract Set<String> getInstrumentMethodNames(); | 69 public abstract Set<String> getInstrumentMethodNames(); |
70 | 70 |
71 /** | 71 /** |
72 * Invoke the payment app to retrieve the instrument details. | 72 * Invoke the payment app to retrieve the instrument details. |
73 * | 73 * |
74 * The callback will be invoked with the resulting payment details or error. | 74 * The callback will be invoked with the resulting payment details or error. |
75 * | 75 * |
76 * @param merchantName The name of the merchant. | 76 * @param merchantName The name of the merchant. |
77 * @param origin The origin of this merchant. | 77 * @param origin The origin of this merchant. |
78 * @param methodDataMap The payment-method specific data for all applicable
payment methods, | 78 * @param certificateChain The site certificate chain of the merchant. |
79 * e.g., whether the app should be invoked in test or p
roduction, a | 79 * @param methodDataMap The payment-method specific data for all applicab
le payment methods, |
80 * merchant identifier, or a public key. | 80 * e.g., whether the app should be invoked in test o
r production, a |
81 * @param total The total amount. | 81 * merchant identifier, or a public key. |
82 * @param displayItems The shopping cart items. | 82 * @param total The total amount. |
83 * @param modifiers The relevant payment details modifiers. | 83 * @param displayItems The shopping cart items. |
84 * @param callback The object that will receive the instrument details. | 84 * @param modifiers The relevant payment details modifiers. |
| 85 * @param callback The object that will receive the instrument detai
ls. |
85 */ | 86 */ |
86 public abstract void invokePaymentApp(String merchantName, String origin, | 87 public abstract void invokePaymentApp(String merchantName, String origin, |
87 Map<String, PaymentMethodData> methodDataMap, PaymentItem total, | 88 byte[][] certificateChain, Map<String, PaymentMethodData> methodData
Map, |
88 List<PaymentItem> displayItems, Map<String, PaymentDetailsModifier>
modifiers, | 89 PaymentItem total, List<PaymentItem> displayItems, |
89 InstrumentDetailsCallback callback); | 90 Map<String, PaymentDetailsModifier> modifiers, InstrumentDetailsCall
back callback); |
90 | 91 |
91 /** | 92 /** |
92 * Cleans up any resources held by the payment instrument. For example, clos
es server | 93 * Cleans up any resources held by the payment instrument. For example, clos
es server |
93 * connections. | 94 * connections. |
94 */ | 95 */ |
95 public abstract void dismissInstrument(); | 96 public abstract void dismissInstrument(); |
96 } | 97 } |
OLD | NEW |