Class: JSer::JSHash
Overview
A JSer class Usage:
JSHash.new({"hello" => "world"}).to_str
Instance Method Summary collapse
-
#initialize(hash) ⇒ JSHash
constructor
A new instance of JSHash.
Methods included from JSer
Constructor Details
#initialize(hash) ⇒ JSHash
Returns a new instance of JSHash.
26 27 28 29 30 31 |
# File 'lib/ngi/utils/jser.rb', line 26 def initialize(hash) super hash.each do |key, val| self[key] = val end end |