Class: Synapse::Serialization::ObjectToJsonConverter

Inherits:
Object
  • Object
show all
Includes:
Converter
Defined in:
lib/synapse/serialization/converter/json.rb

Overview

Converter that converts a Ruby data structure into a JSON string

Instance Method Summary collapse

Methods included from Converter

#convert, #initialize

Instance Method Details

#convert_content(original) ⇒ Object

Parameters:

  • original (Object)

Returns:

  • (Object)


26
27
28
# File 'lib/synapse/serialization/converter/json.rb', line 26

def convert_content(original)
  JSON.generate original, @options
end