Class: Apollo::Formatter::JsonFormatter

Inherits:
BaseFormatter show all
Defined in:
lib/apollo_crawler/formatter/json_formatter.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseFormatter

name_re

Class Method Details

.format(obj) ⇒ Object



36
37
38
# File 'lib/apollo_crawler/formatter/json_formatter.rb', line 36

def self.format(obj)
	 return JSON.pretty_generate(obj)
end

Instance Method Details

#format(obj) ⇒ Object



32
33
34
# File 'lib/apollo_crawler/formatter/json_formatter.rb', line 32

def format(obj)
	return JsonFormatter.format(obj)
end

#nameObject



28
29
30
# File 'lib/apollo_crawler/formatter/json_formatter.rb', line 28

def name()
	return "JSON"
end