Class: Hash
- Inherits:
-
Object
- Object
- Hash
- Defined in:
- lib/silver/cache.rb
Overview
Monkey patches Hash to allow for conversion to a BareHash where all values are strings. This is good for mixing results with Redis results which are always stored as strings.
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#to_bare ⇒ Object
26 27 28 29 30 31 32 |
# File 'lib/silver/cache.rb', line 26 def bhash = BareHash.new self.each{|k,v| bhash[k] = v} bhash end |