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

Side by Side Diff: services/reaper/reaper_binding.h

Issue 988693005: Chromium roll (https://codereview.chromium.org/976353002) (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Fix Clipboard.java Created 5 years, 9 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 SERVICES_REAPER_REAPER_BINDING_H_ 5 #ifndef SERVICES_REAPER_REAPER_BINDING_H_
6 #define SERVICES_REAPER_REAPER_BINDING_H_ 6 #define SERVICES_REAPER_REAPER_BINDING_H_
7 7
8 #include "mojo/public/cpp/bindings/interface_request.h" 8 #include "mojo/public/cpp/bindings/interface_request.h"
9 #include "mojo/public/cpp/bindings/strong_binding.h" 9 #include "mojo/public/cpp/bindings/strong_binding.h"
10 #include "services/reaper/reaper.mojom.h" 10 #include "services/reaper/reaper.mojom.h"
11 #include "services/reaper/transfer.mojom.h" 11 #include "services/reaper/transfer.mojom.h"
12 #include "url/gurl.h" 12 #include "url/gurl.h"
13 13
14 namespace reaper { 14 namespace reaper {
15 15
16 class ReaperImpl; 16 class ReaperImpl;
17 17
18 // ReaperBinding stores the authorative identity (as provided by the shell) of 18 // ReaperBinding stores the authorative identity (as provided by the shell) of
19 // the connecting application, then forwards calls onto the real implementation. 19 // the connecting application, then forwards calls onto the real implementation.
20 class ReaperBinding : public Reaper { 20 class ReaperBinding : public Reaper {
21 public: 21 public:
22 ReaperBinding(const GURL& caller_url, 22 ReaperBinding(const GURL& caller_url,
23 ReaperImpl* impl, 23 ReaperImpl* impl,
24 mojo::InterfaceRequest<Reaper> request); 24 mojo::InterfaceRequest<Reaper> request);
25 25
26 protected: 26 protected:
27 ~ReaperBinding() override = default; 27 ~ReaperBinding() override;
28 28
29 private: 29 private:
30 // Reaper 30 // Reaper
31 void GetApplicationSecret( 31 void GetApplicationSecret(
32 const mojo::Callback<void(uint64)>& callback) override; 32 const mojo::Callback<void(uint64)>& callback) override;
33 void CreateReference(uint32 source_node, uint32 target_node) override; 33 void CreateReference(uint32 source_node, uint32 target_node) override;
34 void DropNode(uint32 node) override; 34 void DropNode(uint32 node) override;
35 void StartTransfer(uint32 node, 35 void StartTransfer(uint32 node,
36 mojo::InterfaceRequest<Transfer> request) override; 36 mojo::InterfaceRequest<Transfer> request) override;
37 void Ping(const mojo::Closure& callback) override; 37 void Ping(const mojo::Closure& callback) override;
38 38
39 GURL caller_url_; 39 GURL caller_url_;
40 ReaperImpl* impl_; 40 ReaperImpl* impl_;
41 mojo::StrongBinding<Reaper> binding_; 41 mojo::StrongBinding<Reaper> binding_;
42 42
43 DISALLOW_COPY_AND_ASSIGN(ReaperBinding); 43 DISALLOW_COPY_AND_ASSIGN(ReaperBinding);
44 }; 44 };
45 45
46 } // namespace reaper 46 } // namespace reaper
47 47
48 #endif // SERVICES_REAPER_REAPER_BINDING_H_ 48 #endif // SERVICES_REAPER_REAPER_BINDING_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698