Sha256: b4f0f4f91e6bcd3c2502bc7e84eaadb773a00a44c3a65bf2ea775f02f46af3d7
Contents?: true
Size: 454 Bytes
Versions: 6
Compression:
Stored size: 454 Bytes
Contents
require 'gson' require 'multi_json/adapter' module MultiJson module Adapters # Use the gson.rb library to dump/load. class Gson < Adapter ParseError = ::Gson::DecodeError def load(string, options={}) string = string.read if StringIO === string ::Gson::Decoder.new(options).decode(string) end def dump(object, options={}) ::Gson::Encoder.new(options).encode(object) end end end end
Version data entries
6 entries across 6 versions & 1 rubygems