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 [JavaPackage="org.chromium.payments.mojom"] | 5 [JavaPackage="org.chromium.payments.mojom"] |
6 module payments.mojom; | 6 module payments.mojom; |
7 | 7 |
8 // The shipping address that the browser process provides to the renderer | 8 // The shipping address that the browser process provides to the renderer |
9 // process. Built either by the browser or a payment app. | 9 // process. Built either by the browser or a payment app. |
10 struct PaymentAddress { | 10 struct PaymentAddress { |
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
176 array<BasicCardType> supported_types; | 176 array<BasicCardType> supported_types; |
177 }; | 177 }; |
178 | 178 |
179 struct PaymentDetailsModifier { | 179 struct PaymentDetailsModifier { |
180 PaymentItem? total; | 180 PaymentItem? total; |
181 array<PaymentItem> additional_display_items; | 181 array<PaymentItem> additional_display_items; |
182 PaymentMethodData method_data; | 182 PaymentMethodData method_data; |
183 }; | 183 }; |
184 | 184 |
185 struct PaymentDetails { | 185 struct PaymentDetails { |
186 PaymentItem total; | 186 PaymentItem? total; |
187 array<PaymentItem> display_items; | 187 array<PaymentItem> display_items; |
188 array<PaymentShippingOption> shipping_options; | 188 array<PaymentShippingOption> shipping_options; |
189 array<PaymentDetailsModifier> modifiers; | 189 array<PaymentDetailsModifier> modifiers; |
190 string error; | 190 string error = ""; |
191 }; | 191 }; |
192 | 192 |
193 enum PaymentShippingType { | 193 enum PaymentShippingType { |
194 SHIPPING, | 194 SHIPPING, |
195 DELIVERY, | 195 DELIVERY, |
196 PICKUP | 196 PICKUP |
197 }; | 197 }; |
198 | 198 |
199 struct PaymentOptions { | 199 struct PaymentOptions { |
200 bool request_payer_name; | 200 bool request_payer_name; |
(...skipping 13 matching lines...) Expand all Loading... |
214 Init(PaymentRequestClient client, | 214 Init(PaymentRequestClient client, |
215 array<PaymentMethodData> method_data, | 215 array<PaymentMethodData> method_data, |
216 PaymentDetails details, | 216 PaymentDetails details, |
217 PaymentOptions options); | 217 PaymentOptions options); |
218 Show(); | 218 Show(); |
219 UpdateWith(PaymentDetails details); | 219 UpdateWith(PaymentDetails details); |
220 Abort(); | 220 Abort(); |
221 Complete(PaymentComplete result); | 221 Complete(PaymentComplete result); |
222 CanMakePayment(); | 222 CanMakePayment(); |
223 }; | 223 }; |
OLD | NEW |