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

Side by Side Diff: content/browser/payments/payment_app_manager.h

Issue 2506093002: PaymentApp: Implement PaymentAppManager.getManifest(). (Closed)
Patch Set: PaymentApp: Implement PaymentAppManager.getManifest(). Created 4 years 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
« no previous file with comments | « components/payments/payment_app.mojom ('k') | content/browser/payments/payment_app_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_ 5 #ifndef CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
6 #define CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_ 6 #define CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 12 matching lines...) Expand all
23 : public NON_EXPORTED_BASE(payments::mojom::PaymentAppManager) { 23 : public NON_EXPORTED_BASE(payments::mojom::PaymentAppManager) {
24 public: 24 public:
25 PaymentAppManager( 25 PaymentAppManager(
26 PaymentAppContext* payment_app_context, 26 PaymentAppContext* payment_app_context,
27 mojo::InterfaceRequest<payments::mojom::PaymentAppManager> request); 27 mojo::InterfaceRequest<payments::mojom::PaymentAppManager> request);
28 28
29 ~PaymentAppManager() override; 29 ~PaymentAppManager() override;
30 30
31 private: 31 private:
32 friend class PaymentAppManagerTest; 32 friend class PaymentAppManagerTest;
33
33 // payments::mojom::PaymentAppManager methods: 34 // payments::mojom::PaymentAppManager methods:
34 void SetManifest(const std::string& scope, 35 void SetManifest(const std::string& scope,
35 payments::mojom::PaymentAppManifestPtr manifest, 36 payments::mojom::PaymentAppManifestPtr manifest,
36 const SetManifestCallback& callback) override; 37 const SetManifestCallback& callback) override;
38 void GetManifest(const std::string& scope,
39 const GetManifestCallback& callback) override;
40
41 // SetManifest callbacks
37 void DidFindRegistrationToSetManifest( 42 void DidFindRegistrationToSetManifest(
38 payments::mojom::PaymentAppManifestPtr manifest, 43 payments::mojom::PaymentAppManifestPtr manifest,
39 const SetManifestCallback& callback, 44 const SetManifestCallback& callback,
40 ServiceWorkerStatusCode status, 45 ServiceWorkerStatusCode status,
41 scoped_refptr<ServiceWorkerRegistration> registration); 46 scoped_refptr<ServiceWorkerRegistration> registration);
42 void DidSetManifest(const SetManifestCallback& callback, 47 void DidSetManifest(const SetManifestCallback& callback,
43 ServiceWorkerStatusCode status); 48 ServiceWorkerStatusCode status);
44 49
50 // GetManifest callbacks
51 void DidFindRegistrationToGetManifest(
52 const GetManifestCallback& callback,
53 ServiceWorkerStatusCode status,
54 scoped_refptr<ServiceWorkerRegistration> registration);
55 void DidGetManifest(const GetManifestCallback& callback,
56 const std::vector<std::string>& data,
57 ServiceWorkerStatusCode status);
58
45 // Called when an error is detected on binding_. 59 // Called when an error is detected on binding_.
46 void OnConnectionError(); 60 void OnConnectionError();
47 61
48 // payment_app_context_ owns this. 62 // PaymentAppContext owns PaymentAppManager
49 PaymentAppContext* payment_app_context_; 63 PaymentAppContext* payment_app_context_;
50 64
51 mojo::Binding<payments::mojom::PaymentAppManager> binding_; 65 mojo::Binding<payments::mojom::PaymentAppManager> binding_;
52 66
53 base::WeakPtrFactory<PaymentAppManager> weak_ptr_factory_; 67 base::WeakPtrFactory<PaymentAppManager> weak_ptr_factory_;
54 68
55 DISALLOW_COPY_AND_ASSIGN(PaymentAppManager); 69 DISALLOW_COPY_AND_ASSIGN(PaymentAppManager);
56 }; 70 };
57 71
58 } // namespace content 72 } // namespace content
59 73
60 #endif // CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_ 74 #endif // CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
OLDNEW
« no previous file with comments | « components/payments/payment_app.mojom ('k') | content/browser/payments/payment_app_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698