Module: DataBindings::Adapters::BSON
- Includes:
- Ruby, GemRequirement
- Defined in:
- lib/data_bindings/adapters/bson.rb
Defined Under Namespace
Modules: Convert
Instance Method Summary collapse
-
#from_bson(str) ⇒ RubyObjectAdapter, RubyArrayAdapter
Constructs a wrapped object from a JSON string.
Methods included from GemRequirement
Methods included from Ruby
#from_ruby, #from_ruby_array, #from_ruby_hash
Instance Method Details
#from_bson(str) ⇒ RubyObjectAdapter, RubyArrayAdapter
Constructs a wrapped object from a JSON string
10 11 12 |
# File 'lib/data_bindings/adapters/bson.rb', line 10 def from_bson(str) from_ruby(::BSON.deserialize(str.unpack("C*"))) end |