Class: Elastic::Transport::Transport::Serializer::MultiJson
- Inherits:
-
Object
- Object
- Elastic::Transport::Transport::Serializer::MultiJson
- Includes:
- Base
- Defined in:
- lib/elastic/transport/transport/serializer/multi_json.rb
Overview
A default JSON serializer (using [MultiJSON](rubygems.org/gems/multi_json))
Instance Method Summary collapse
-
#dump(object, options = {}) ⇒ Object
Serialize a Hash to JSON string.
-
#load(string, options = {}) ⇒ Object
De-serialize a Hash from JSON string.
Methods included from Base
Instance Method Details
#dump(object, options = {}) ⇒ Object
Serialize a Hash to JSON string
45 46 47 |
# File 'lib/elastic/transport/transport/serializer/multi_json.rb', line 45 def dump(object, = {}) ::MultiJson.dump(object, ) end |
#load(string, options = {}) ⇒ Object
De-serialize a Hash from JSON string
39 40 41 |
# File 'lib/elastic/transport/transport/serializer/multi_json.rb', line 39 def load(string, = {}) ::MultiJson.load(string, ) end |