lib/mongoid/extensions/big_decimal.rb
# Turn the object from the ruby type we deal with to a Mongo friendly
# type.
#
# @example Mongoize the object.
#   object.mongoize
#
# @return [ Object ] The object.
Turn the object from the ruby type we deal with to a Mongo friendly
type.
Turn the object from the ruby type we deal with to a Mongo friendly type .
def mongoize
        if Mongoid.map_big_decimal_to_decimal128
          BSON::Decimal128.new(self)
        else
          to_s
        end
      end
def mongoize if Mongoid . map_big_decimal_to_decimal128 BSON :: Decimal128 . new ( self ) else to_s end end
Turn the object from the ruby type we deal with to a Mongo friendly
type.
Turn the object from the ruby type we deal with to a Mongo friendly type .
None
 Object 
example
Mongoize the object. object.mongoize
Mongoize the object . object . mongoize