Class: Hutch::Serializers::JSON
- Inherits:
-
Object
- Object
- Hutch::Serializers::JSON
- Defined in:
- lib/hutch/serializers/json.rb
Class Method Summary collapse
Class Method Details
.binary? ⇒ Boolean
16 |
# File 'lib/hutch/serializers/json.rb', line 16 def self.binary? ; false ; end |
.content_type ⇒ Object
18 |
# File 'lib/hutch/serializers/json.rb', line 18 def self.content_type ; 'application/json' ; end |
.decode(payload) ⇒ Object
12 13 14 |
# File 'lib/hutch/serializers/json.rb', line 12 def self.decode(payload) ::MultiJson.load(payload).with_indifferent_access end |
.encode(payload) ⇒ Object
8 9 10 |
# File 'lib/hutch/serializers/json.rb', line 8 def self.encode(payload) ::MultiJson.dump(payload) end |