Home | History | Annotate | Download | only in disks

Lines Matching defs:device_path

110     std::string device_path = mount_point->second.source_path;
111 DiskMap::const_iterator disk = disks_.find(device_path);
113 LOG(ERROR) << "Device with path \"" << device_path << "\" not found.";
114 OnFormatDevice(device_path, false);
122 device_path));
127 const std::string& device_path,
132 int device_path_len = device_path.length();
135 strncmp(device_path.c_str(), it->second->device_path().c_str(),
143 if (disks_.find(device_path) == disks_.end()) {
145 << device_path << ", with error: " << kDeviceNotFound;
214 if (disks_.find(disk->device_path()) != disks_.end()) {
219 disks_.insert(std::make_pair(disk->device_path(), disk));
375 void OnUnmountPathForFormat(const std::string& device_path,
378 disks_.find(device_path) != disks_.end()) {
379 FormatUnmountedDevice(device_path);
381 OnFormatDevice(device_path, false);
386 void FormatUnmountedDevice(const std::string& device_path) {
387 DiskMap::const_iterator disk = disks_.find(device_path);
392 device_path,
396 device_path),
399 device_path,
405 void OnFormatDevice(const std::string& device_path, bool success) {
407 NotifyFormatStatusUpdate(FORMAT_STARTED, error_code, device_path);
418 LOG(WARNING) << "Found disk " << disk_info.device_path();
421 DiskMap::iterator iter = disks_.find(disk_info.device_path());
427 Disk* disk = new Disk(disk_info.device_path(),
446 disks_.insert(std::make_pair(disk_info.device_path(), disk));
481 std::string device_path = device_path_arg;
485 device_path,
493 DiskMountManager::DiskMap::iterator iter = disks_.find(device_path);
503 system_path_prefixes_.insert(device_path);
504 NotifyDeviceStatusUpdate(DEVICE_ADDED, device_path);
508 system_path_prefixes_.erase(device_path);
509 NotifyDeviceStatusUpdate(DEVICE_REMOVED, device_path);
513 NotifyDeviceStatusUpdate(DEVICE_SCANNED, device_path);
519 ParseFormatFinishedPath(device_path, &path, &error_code);
544 const std::string& device_path) {
545 FOR_EACH_OBSERVER(Observer, observers_, OnDeviceEvent(event, device_path));
558 const std::string& device_path) {
560 OnFormatEvent(event, error_code, device_path));
565 std::string* device_path,
581 it->second->device_path() == path) {
582 *device_path = it->second->device_path();
622 DiskMountManager::Disk::Disk(const std::string& device_path,
641 : device_path_(device_path),