Module: BSON::Time
- Defined in:
- lib/bson/time.rb
Overview
Injects behaviour for encoding and decoding time values to and from raw bytes as specified by the BSON spec.
Defined Under Namespace
Modules: ClassMethods
Constant Summary collapse
- BSON_TYPE =
A time is type 0x09 in the BSON spec.
9.chr.force_encoding(BINARY).freeze
Instance Method Summary collapse
-
#to_bson(encoded = ''.force_encoding(BINARY)) ⇒ String
Get the time as encoded BSON.