Sha256: 832fd35c30cd08fa80513601a135187a1abb21d90d8fc52f1f79f23145ce1800

Contents?: true

Size: 425 Bytes

Versions: 125

Compression:

Stored size: 425 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 = {})
        ::Gson::Decoder.new(options).decode(string)
      end

      def dump(object, options = {})
        ::Gson::Encoder.new(options).encode(object)
      end
    end
  end
end

Version data entries

125 entries across 106 versions & 22 rubygems

Version Path
vagrant-unbundled-2.2.6.2 vendor/bundle/ruby/2.6.0/gems/multi_json-1.14.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.6.1 vendor/bundle/ruby/2.6.0/gems/multi_json-1.14.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.6.0 vendor/bundle/ruby/2.6.0/gems/multi_json-1.14.1/lib/multi_json/adapters/gson.rb
multi_json-1.14.1 lib/multi_json/adapters/gson.rb
multi_json-1.14.0 lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.5.0 vendor/bundle/ruby/2.6.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.5.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.4.0 vendor/bundle/ruby/2.6.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.4.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.3.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.2.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.2.0.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.1.4.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.1.2.0 vendor/bundle/ruby/2.3.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
logstash-filter-device_detection-1.0.7-java vendor/bundle/jruby/1.9/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb
mercadopago-custom-checkout-0.1.2 .gs/gems/multi_json-1.12.1/lib/multi_json/adapters/gson.rb
vagrant-unbundled-2.1.1.0 vendor/bundle/ruby/2.5.0/gems/multi_json-1.13.1/lib/multi_json/adapters/gson.rb