class Chewy::Search::Parameters::Load

Acts like standard hash storage, with one exception: all the keys are deeply symbolized for convenience.

@see Chewy::Search::Request#load @see Chewy::Search::Loader

Public Instance Methods

render() click to toggle source

Doesn’t render anythig, has specific handling logic.

# File lib/chewy/search/parameters/load.rb, line 22
def render; end
update!(other_value) click to toggle source

Simply merges two value hashes on update

@see Chewy::Search::Parameters::Storage#update! @param other_value [{String, Symbol => Object}] any acceptable storage value @return [{Symbol => Object}] updated value

# File lib/chewy/search/parameters/load.rb, line 17
def update!(other_value)
  value.merge!(normalize(other_value))
end

Private Instance Methods

normalize(value) click to toggle source
# File lib/chewy/search/parameters/load.rb, line 26
def normalize(value)
  (value || {}).deep_symbolize_keys
end