Class: EventStore::HTTP::JSON::Deserialize::ObjectClass

Inherits:
Hash
  • Object
show all
Defined in:
lib/event_store/http/json/deserialize.rb

Instance Method Summary collapse

Instance Method Details

#[]=(raw_key, value) ⇒ Object



10
11
12
13
14
# File 'lib/event_store/http/json/deserialize.rb', line 10

def []=(raw_key, value)
  key = key_cache[raw_key]

  super key, value
end

#key_cacheObject



16
17
18
19
20
# File 'lib/event_store/http/json/deserialize.rb', line 16

def key_cache
  @@key_cache ||= Hash.new do |cache, raw_key|
    cache[raw_key] = Casing::Underscore.(raw_key).to_sym
  end
end