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

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

Issue 2476343002: PaymentApp: Initial implementation for PaymentAppManager.setManifest(). (Closed)
Patch Set: fix lint error Created 4 years, 1 month 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
6 #define CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
7
8 #include <string>
9
10 #include "base/macros.h"
11 #include "base/memory/weak_ptr.h"
12 #include "components/payments/payment_app.mojom.h"
13 #include "content/common/content_export.h"
14 #include "mojo/public/cpp/bindings/binding.h"
15
16 namespace content {
17
18 class PaymentAppContext;
19
20 class CONTENT_EXPORT PaymentAppManager
21 : public NON_EXPORTED_BASE(payments::mojom::PaymentAppManager) {
22 public:
23 PaymentAppManager(
24 PaymentAppContext* payment_app_context,
25 mojo::InterfaceRequest<payments::mojom::PaymentAppManager> request);
26
27 ~PaymentAppManager() override;
28
29 private:
30 // payments::mojom::PaymentAppManager methods:
31 void SetManifest(const std::string& scope,
32 payments::mojom::PaymentAppManifestPtr manifest,
33 const SetManifestCallback& callback) override;
34
35 // Called when an error is detected on binding_.
36 void OnConnectionError();
37
38 // payment_app_context_ owns this.
39 PaymentAppContext* payment_app_context_;
40
41 mojo::Binding<payments::mojom::PaymentAppManager> binding_;
42
43 base::WeakPtrFactory<PaymentAppManager> weak_ptr_factory_;
44
45 DISALLOW_COPY_AND_ASSIGN(PaymentAppManager);
46 };
47
48 } // namespace content
49
50 #endif // CONTENT_BROWSER_PAYMENTS_PAYMENT_APP_MANAGER_H_
OLDNEW
« no previous file with comments | « content/browser/payments/payment_app_context.cc ('k') | content/browser/payments/payment_app_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698