Method: Struct.from_hash
- Defined in:
- lib/libis/tools/extend/struct.rb
.from_hash(h) ⇒ Object
17 18 19 20 |
# File 'lib/libis/tools/extend/struct.rb', line 17 def self.from_hash(h) h.symbolize_keys! members.inject(new) {|o,m| o[m] = h[m] if h.key?(m); o} end |