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

Side by Side Diff: services/files/files_impl.h

Issue 1975993002: Change InterfaceFactory<I>::Create() to take a ConnectionContext instead of an ApplicationConnectio… (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « services/device_info/device_info.cc ('k') | services/files/files_impl.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 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_FILES_FILES_IMPL_H_ 5 #ifndef SERVICES_FILES_FILES_IMPL_H_
6 #define SERVICES_FILES_FILES_IMPL_H_ 6 #define SERVICES_FILES_FILES_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "mojo/public/cpp/bindings/interface_request.h" 11 #include "mojo/public/cpp/bindings/interface_request.h"
12 #include "mojo/public/cpp/bindings/strong_binding.h" 12 #include "mojo/public/cpp/bindings/strong_binding.h"
13 #include "mojo/services/files/interfaces/files.mojom.h" 13 #include "mojo/services/files/interfaces/files.mojom.h"
14 14
15 namespace mojo { 15 namespace mojo {
16 16
17 class ApplicationConnection; 17 struct ConnectionContext;
18 18
19 namespace files { 19 namespace files {
20 20
21 class FilesImpl : public Files { 21 class FilesImpl : public Files {
22 public: 22 public:
23 FilesImpl(ApplicationConnection* connection, InterfaceRequest<Files> request); 23 FilesImpl(const ConnectionContext& connection_context,
24 InterfaceRequest<Files> request);
24 ~FilesImpl() override; 25 ~FilesImpl() override;
25 26
26 // |Files| implementation: 27 // |Files| implementation:
27 // We provide a "private" temporary file system as the default. In Debug 28 // We provide a "private" temporary file system as the default. In Debug
28 // builds, we also provide access to a common file system named "debug" 29 // builds, we also provide access to a common file system named "debug"
29 // (stored under ~/MojoDebug). 30 // (stored under ~/MojoDebug).
30 void OpenFileSystem(const mojo::String& file_system, 31 void OpenFileSystem(const mojo::String& file_system,
31 InterfaceRequest<Directory> directory, 32 InterfaceRequest<Directory> directory,
32 const OpenFileSystemCallback& callback) override; 33 const OpenFileSystemCallback& callback) override;
33 34
34 private: 35 private:
35 const std::string client_url_; 36 const std::string client_url_;
36 37
37 StrongBinding<Files> binding_; 38 StrongBinding<Files> binding_;
38 39
39 DISALLOW_COPY_AND_ASSIGN(FilesImpl); 40 DISALLOW_COPY_AND_ASSIGN(FilesImpl);
40 }; 41 };
41 42
42 } // namespace files 43 } // namespace files
43 } // namespace mojo 44 } // namespace mojo
44 45
45 #endif // SERVICES_FILES_FILES_IMPL_H_ 46 #endif // SERVICES_FILES_FILES_IMPL_H_
OLDNEW
« no previous file with comments | « services/device_info/device_info.cc ('k') | services/files/files_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698