Sha256: 5a6441990193516793e33c3bece07e756513bd9d6e51611ded2af44590d0a0de
Contents?: true
Size: 473 Bytes
Versions: 11
Compression:
Stored size: 473 Bytes
Contents
require 'gson' require 'stringio' 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
11 entries across 4 versions & 4 rubygems