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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentInstrument.java

Issue 2640743005: PaymentApp: Implement invokePaymentApp for Android (Closed)
Patch Set: Fix a compile error Created 3 years, 11 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
OLDNEW
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 org.chromium.content_public.browser.WebContents; 7 import org.chromium.content_public.browser.WebContents;
8 import org.chromium.payments.mojom.PaymentDetailsModifier;
8 import org.chromium.payments.mojom.PaymentItem; 9 import org.chromium.payments.mojom.PaymentItem;
9 import org.chromium.payments.mojom.PaymentMethodData; 10 import org.chromium.payments.mojom.PaymentMethodData;
10 11
11 import java.util.Collections; 12 import java.util.Collections;
12 import java.util.HashSet; 13 import java.util.HashSet;
13 import java.util.List; 14 import java.util.List;
14 import java.util.Map; 15 import java.util.Map;
15 import java.util.Set; 16 import java.util.Set;
16 17
17 /** 18 /**
(...skipping 30 matching lines...) Expand all
48 49
49 mMethodNames = new HashSet<String>(option.enabledMethods); 50 mMethodNames = new HashSet<String>(option.enabledMethods);
50 } 51 }
51 52
52 @Override 53 @Override
53 public Set<String> getInstrumentMethodNames() { 54 public Set<String> getInstrumentMethodNames() {
54 return Collections.unmodifiableSet(mMethodNames); 55 return Collections.unmodifiableSet(mMethodNames);
55 } 56 }
56 57
57 @Override 58 @Override
58 public void invokePaymentApp(String merchantName, String origin, PaymentItem total, 59 public void invokePaymentApp(String merchantName, String origin,
59 List<PaymentItem> cart, Map<String, PaymentMethodData> methodDataMap , 60 Map<String, PaymentMethodData> methodData, PaymentItem total,
61 List<PaymentItem> displayItems, Map<String, PaymentDetailsModifier> modifiers,
60 InstrumentDetailsCallback callback) { 62 InstrumentDetailsCallback callback) {
61 ServiceWorkerPaymentAppBridge.invokePaymentApp(mWebContents, mAppRegistr ationId, mOption.id, 63 ServiceWorkerPaymentAppBridge.invokePaymentApp(mWebContents, mAppRegistr ationId, mOption.id,
62 new HashSet<>(methodDataMap.values())); 64 origin, new HashSet<>(methodData.values()), total, displayItems,
65 new HashSet<>(modifiers.values()));
63 } 66 }
64 67
65 @Override 68 @Override
66 public void dismissInstrument() {} 69 public void dismissInstrument() {}
67 } 70 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698