Class: Smoke::Transformers::Json

Inherits:
Smoke::Transformer show all
Defined in:
lib/smoke/transformers/json.rb

Class Method Summary collapse

Class Method Details

.generate(tree_name, objects) ⇒ Object



6
7
8
# File 'lib/smoke/transformers/json.rb', line 6

def self.generate(tree_name, objects)
  ::JSON.generate(objects)
end

.parse(string) ⇒ Object



10
11
12
# File 'lib/smoke/transformers/json.rb', line 10

def self.parse(string)
  ::Crack::JSON.parse(string)
end