Class: Array

Inherits:
Object show all
Defined in:
lib/mongo_record/core_ext.rb

Instance Method Summary collapse

Instance Method Details

#to_mongo_valueObject

Convert an Array to a Mongo value. Used by MongoRecord::Base when saving data to Mongo.



39
40
41
# File 'lib/mongo_record/core_ext.rb', line 39

def to_mongo_value
  self.collect {|v| v.to_mongo_value}
end