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

Side by Side Diff: chromeos/disks/disk_mount_manager.h

Issue 2451603002: Add a method to remount all removable devices in DiskMountManager. (Closed)
Patch Set: Do not pass mount path as mount_label because it causes test failure on some platforms. 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
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_ 5 #ifndef CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_
6 #define CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_ 6 #define CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 // Unmounts a mounted disk. 287 // Unmounts a mounted disk.
288 // |UnmountOptions| enum defined in chromeos/dbus/cros_disks_client.h. 288 // |UnmountOptions| enum defined in chromeos/dbus/cros_disks_client.h.
289 // When the method is complete, |callback| will be called and observers' 289 // When the method is complete, |callback| will be called and observers'
290 // |OnMountEvent| will be raised. 290 // |OnMountEvent| will be raised.
291 // 291 //
292 // |callback| may be empty, in which case it gets ignored. 292 // |callback| may be empty, in which case it gets ignored.
293 virtual void UnmountPath(const std::string& mount_path, 293 virtual void UnmountPath(const std::string& mount_path,
294 UnmountOptions options, 294 UnmountOptions options,
295 const UnmountPathCallback& callback) = 0; 295 const UnmountPathCallback& callback) = 0;
296 296
297 virtual void RemountAllRemovableDrives(chromeos::MountAccessMode mode) = 0;
hashimoto 2016/10/26 06:05:12 Please add a comment to describe what this method
yamaguchi 2016/10/27 06:34:55 Done.
298
297 // Formats Device given its mount path. Unmounts the device. 299 // Formats Device given its mount path. Unmounts the device.
298 // Example: mount_path: /media/VOLUME_LABEL 300 // Example: mount_path: /media/VOLUME_LABEL
299 virtual void FormatMountedDevice(const std::string& mount_path) = 0; 301 virtual void FormatMountedDevice(const std::string& mount_path) = 0;
300 302
301 // Unmounts device_path and all of its known children. 303 // Unmounts device_path and all of its known children.
302 virtual void UnmountDeviceRecursively( 304 virtual void UnmountDeviceRecursively(
303 const std::string& device_path, 305 const std::string& device_path,
304 const UnmountDeviceRecursivelyCallbackType& callback) = 0; 306 const UnmountDeviceRecursivelyCallbackType& callback) = 0;
305 307
306 // Used in tests to initialize the manager's disk and mount point sets. 308 // Used in tests to initialize the manager's disk and mount point sets.
(...skipping 21 matching lines...) Expand all
328 330
329 // Returns a pointer to the global DiskMountManager instance. 331 // Returns a pointer to the global DiskMountManager instance.
330 // Initialize() should already have been called. 332 // Initialize() should already have been called.
331 static DiskMountManager* GetInstance(); 333 static DiskMountManager* GetInstance();
332 }; 334 };
333 335
334 } // namespace disks 336 } // namespace disks
335 } // namespace chromeos 337 } // namespace chromeos
336 338
337 #endif // CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_ 339 #endif // CHROMEOS_DISKS_DISK_MOUNT_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698