| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "chrome/browser/chromeos/file_system_provider/provided_file_system_info
.h" | 5 #include "chrome/browser/chromeos/file_system_provider/provided_file_system_info
.h" |
| 6 #include "base/logging.h" |
| 6 | 7 |
| 7 namespace chromeos { | 8 namespace chromeos { |
| 8 namespace file_system_provider { | 9 namespace file_system_provider { |
| 9 | 10 |
| 10 MountOptions::MountOptions() : writable(false), supports_notify_tag(false) { | 11 MountOptions::MountOptions() |
| 12 : writable(false), supports_notify_tag(false), opened_files_limit(0) { |
| 11 } | 13 } |
| 12 | 14 |
| 13 MountOptions::MountOptions(const std::string& file_system_id, | 15 MountOptions::MountOptions(const std::string& file_system_id, |
| 14 const std::string& display_name) | 16 const std::string& display_name) |
| 15 : file_system_id(file_system_id), | 17 : file_system_id(file_system_id), |
| 16 display_name(display_name), | 18 display_name(display_name), |
| 17 writable(false), | 19 writable(false), |
| 18 supports_notify_tag(false) { | 20 supports_notify_tag(false), |
| 21 opened_files_limit(0) { |
| 19 } | 22 } |
| 20 | 23 |
| 21 ProvidedFileSystemInfo::ProvidedFileSystemInfo() | 24 ProvidedFileSystemInfo::ProvidedFileSystemInfo() |
| 22 : writable_(false), supports_notify_tag_(false) { | 25 : writable_(false), supports_notify_tag_(false) { |
| 23 } | 26 } |
| 24 | 27 |
| 25 ProvidedFileSystemInfo::ProvidedFileSystemInfo( | 28 ProvidedFileSystemInfo::ProvidedFileSystemInfo( |
| 26 const std::string& extension_id, | 29 const std::string& extension_id, |
| 27 const MountOptions& mount_options, | 30 const MountOptions& mount_options, |
| 28 const base::FilePath& mount_path) | 31 const base::FilePath& mount_path) |
| 29 : extension_id_(extension_id), | 32 : extension_id_(extension_id), |
| 30 file_system_id_(mount_options.file_system_id), | 33 file_system_id_(mount_options.file_system_id), |
| 31 display_name_(mount_options.display_name), | 34 display_name_(mount_options.display_name), |
| 32 writable_(mount_options.writable), | 35 writable_(mount_options.writable), |
| 33 supports_notify_tag_(mount_options.supports_notify_tag), | 36 supports_notify_tag_(mount_options.supports_notify_tag), |
| 37 opened_files_limit_(mount_options.opened_files_limit), |
| 34 mount_path_(mount_path) { | 38 mount_path_(mount_path) { |
| 39 DCHECK_LE(0, mount_options.opened_files_limit); |
| 35 } | 40 } |
| 36 | 41 |
| 37 ProvidedFileSystemInfo::~ProvidedFileSystemInfo() {} | 42 ProvidedFileSystemInfo::~ProvidedFileSystemInfo() {} |
| 38 | 43 |
| 39 } // namespace file_system_provider | 44 } // namespace file_system_provider |
| 40 } // namespace chromeos | 45 } // namespace chromeos |
| OLD | NEW |