Module: RapidJSON
- Defined in:
- lib/rapidjson.rb,
lib/rapidjson.rb,
lib/rapidjson/version.rb,
lib/rapidjson/json_gem.rb,
lib/rapidjson/active_support_encoder.rb
Defined Under Namespace
Modules: JSONGem
Classes: ActiveSupportEncoder, Coder, EncodeError, Error, Fragment, ParseError
Constant Summary
collapse
- VERSION =
"0.2.3"
Class Method Summary
collapse
Class Method Details
.dump(object) ⇒ Object
Also known as:
encode
36
37
38
|
# File 'lib/rapidjson.rb', line 36
def dump(object)
DEFAULT_CODER.dump(object)
end
|
.json_escape ⇒ Object
.load(string) ⇒ Object
Also known as:
parse
31
32
33
|
# File 'lib/rapidjson.rb', line 31
def load(string)
DEFAULT_CODER.load(string)
end
|
.pretty_encode(object) ⇒ Object
41
42
43
|
# File 'lib/rapidjson.rb', line 41
def pretty_encode(object)
PRETTY_CODER.dump(object)
end
|
.valid_json?(string) ⇒ Boolean
45
46
47
|
# File 'lib/rapidjson.rb', line 45
def valid_json?(string)
DEFAULT_CODER.valid_json?(string)
end
|