Module: Moped::BSON::Extensions::Regexp
- Included in:
- Regexp
- Defined in:
- lib/moped/bson/extensions/regexp.rb
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
Instance Method Details
#__bson_dump__(io, key) ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/moped/bson/extensions/regexp.rb', line 7 def __bson_dump__(io, key) io << Types::REGEX io << key.to_bson_cstring io << source.to_bson_cstring io << 'i' if ( & ::Regexp::IGNORECASE) != 0 io << 'ms' if ( & ::Regexp::MULTILINE) != 0 io << 'x' if ( & ::Regexp::EXTENDED) != 0 io << NULL_BYTE end |