Method: Win32::Registry#each_key

Defined in:
lib/win32/registry.rb

#each_keyObject

Enumerate subkeys.

subkey is String which contains name of subkey. wtime is last write time as FILETIME (64-bit integer). (see Registry.wtime2time)



603
604
605
606
607
608
609
610
611
612
613
614
615
616
# File 'lib/win32/registry.rb', line 603

def each_key
  index = 0
  while true
    begin
      subkey, wtime = API.EnumKey(@hkey, index)
    rescue Error
      break
    end
    subkey = export_string(subkey)
    yield subkey, wtime
    index += 1
  end
  index
end