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

Side by Side Diff: components/filesystem/file_system_impl.h

Issue 2182643003: Remove shell::Connection* parameter to InterfaceFactory<T>::Create() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 4 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 | « components/filesystem/file_system_app.cc ('k') | components/filesystem/file_system_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 COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_ 5 #ifndef COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_
6 #define COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_ 6 #define COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_
7 7
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "components/filesystem/public/interfaces/file_system.mojom.h" 10 #include "components/filesystem/public/interfaces/file_system.mojom.h"
11 #include "components/filesystem/shared_temp_dir.h" 11 #include "components/filesystem/shared_temp_dir.h"
12 #include "mojo/public/cpp/bindings/interface_request.h" 12 #include "mojo/public/cpp/bindings/interface_request.h"
13 #include "mojo/public/cpp/bindings/strong_binding.h" 13 #include "mojo/public/cpp/bindings/strong_binding.h"
14 14
15 namespace base { 15 namespace base {
16 class FilePath; 16 class FilePath;
17 } 17 }
18 18
19 namespace shell { 19 namespace shell {
20 class Connection; 20 class Identity;
21 } 21 }
22 22
23 namespace filesystem { 23 namespace filesystem {
24 class FileSystemApp; 24 class FileSystemApp;
25 25
26 class LockTable; 26 class LockTable;
27 27
28 // The base implementation of FileSystemImpl. 28 // The base implementation of FileSystemImpl.
29 class FileSystemImpl : public mojom::FileSystem { 29 class FileSystemImpl : public mojom::FileSystem {
30 public: 30 public:
31 // |persistent_dir| is the directory served to callers of 31 // |persistent_dir| is the directory served to callers of
32 // |OpenPersistentFileSystem(). 32 // |OpenPersistentFileSystem().
33 FileSystemImpl(shell::Connection* connection, 33 FileSystemImpl(const shell::Identity& remote_identity,
34 mojo::InterfaceRequest<mojom::FileSystem> request, 34 mojo::InterfaceRequest<mojom::FileSystem> request,
35 base::FilePath persistent_dir, 35 base::FilePath persistent_dir,
36 scoped_refptr<LockTable> lock_table); 36 scoped_refptr<LockTable> lock_table);
37 ~FileSystemImpl() override; 37 ~FileSystemImpl() override;
38 38
39 // |Files| implementation: 39 // |Files| implementation:
40 void OpenTempDirectory(mojo::InterfaceRequest<mojom::Directory> directory, 40 void OpenTempDirectory(mojo::InterfaceRequest<mojom::Directory> directory,
41 const OpenTempDirectoryCallback& callback) override; 41 const OpenTempDirectoryCallback& callback) override;
42 void OpenPersistentFileSystem( 42 void OpenPersistentFileSystem(
43 mojo::InterfaceRequest<mojom::Directory> directory, 43 mojo::InterfaceRequest<mojom::Directory> directory,
44 const OpenPersistentFileSystemCallback& callback) override; 44 const OpenPersistentFileSystemCallback& callback) override;
45 45
46 private: 46 private:
47 const std::string remote_application_name_; 47 const std::string remote_application_name_;
48 mojo::StrongBinding<mojom::FileSystem> binding_; 48 mojo::StrongBinding<mojom::FileSystem> binding_;
49 scoped_refptr<LockTable> lock_table_; 49 scoped_refptr<LockTable> lock_table_;
50 50
51 base::FilePath persistent_dir_; 51 base::FilePath persistent_dir_;
52 52
53 DISALLOW_COPY_AND_ASSIGN(FileSystemImpl); 53 DISALLOW_COPY_AND_ASSIGN(FileSystemImpl);
54 }; 54 };
55 55
56 } // namespace filesystem 56 } // namespace filesystem
57 57
58 #endif // COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_ 58 #endif // COMPONENTS_FILESYSTEM_FILE_SYSTEM_IMPL_H_
OLDNEW
« no previous file with comments | « components/filesystem/file_system_app.cc ('k') | components/filesystem/file_system_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698