Module: Yajl

Defined in:
lib/yajl.rb,
ext/yajl/yajl_ext.c,
lib/yajl/version.rb,
lib/yajl/http_stream.rb,
lib/yajl/gzip/stream_writer.rb,
lib/yajl/gzip/stream_reader.rb,
lib/yajl/bzip2/stream_writer.rb,
lib/yajl/bzip2/stream_reader.rb,
lib/yajl/deflate/stream_reader.rb,
lib/yajl/deflate/stream_writer.rb

Overview

Yajl

Ruby bindings to the excellent Yajl (Yet Another JSON Parser) ANSI C library.

Defined Under Namespace

Modules: Bzip2, Deflate, Gzip Classes: EncodeError, Encoder, HttpStream, ParseError, Parser

Constant Summary

VERSION =
"0.8.3"

Class Method Summary collapse

Class Method Details

.dump(obj, *args, &block) ⇒ Object

For compatibility, has the same signature of Yajl::Encoder.encode



22
23
24
# File 'lib/yajl.rb', line 22

def self.dump(obj, *args, &block)
  Encoder.encode(obj, args, &block)
end

.load(str_or_io, options = {}, read_bufsize = nil, &block) ⇒ Object

For compatibility, has the same signature of Yajl::Parser.parse



17
18
19
# File 'lib/yajl.rb', line 17

def self.load(str_or_io, options={}, read_bufsize=nil, &block)
  Parser.parse(str_or_io, options, read_bufsize, &block)
end