Module: WinMountProbe
- Defined in:
- lib/fs/modules/WinMountProbe.rb
Constant Summary collapse
- WIN_FS_TYPES =
["FAT32", "NTFS", "ntfs"]
Class Method Summary collapse
Class Method Details
.probe(fs) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/fs/modules/WinMountProbe.rb', line 7 def self.probe(fs) unless WIN_FS_TYPES.include?(fs.fsType) $log.debug "WinMountProbe << FALSE because file system (#{fs.fsType}) is not supported" if $log return false end begin si = Win32::SystemPath.systemIdentifier(fs) # This method will raise an error if it does not find the file system boot markers Win32::SystemPath.systemRoot(fs, si) return true rescue $log.debug "WinMountProbe << FALSE because #{$!} was found" if $log end false end |