Class: Hash

Inherits:
Object
  • Object
show all
Defined in:
lib/serrano/utils.rb,
lib/serrano/utils.rb

Instance Method Summary collapse

Instance Method Details

#tostringsObject



20
21
22
# File 'lib/serrano/utils.rb', line 20

def tostrings
  Hash[self.map{|(k,v)| [k.to_s,v]}]
end

#tosymbolsObject



26
27
28
# File 'lib/serrano/utils.rb', line 26

def tosymbols
  Hash[self.map{|(k,v)| [k.to_sym,v]}]
end