Class: Hash

Inherits:
Object
  • Object
show all
Defined in:
lib/openhash/openhash.rb

Direct Known Subclasses

HashWithIndifferentAccess

Instance Method Summary collapse

Instance Method Details

#to_openhashObject



39
40
41
42
43
# File 'lib/openhash/openhash.rb', line 39

def to_openhash
  hash = self.dup
  hash.each {|k,v| hash[k] = v.to_openhash if v.is_a?(Hash) }
  OpenHash.new(hash)
end