Class: BSON::Document
- Inherits:
-
Hash
- Object
- Hash
- BSON::Document
- Defined in:
- lib/bson/document.rb
Overview
Note:
The specification is: document ::= int32 e_list “x00”
This module provides behaviour for serializing and deserializing entire BSON documents, according to the BSON specification.
Instance Method Summary collapse
-
#[](key) ⇒ Object
Get a value from the document for the provided key.
Instance Method Details
#[](key) ⇒ Object
Get a value from the document for the provided key. Can use string or symbol access, but the fastest will be to always provide a key that is of the same type as the stored keys.
52 53 54 |
# File 'lib/bson/document.rb', line 52 def [](key) super(key) || super(key.to_s) end |