Method: Updater::ORM::Mongo#initialize

Defined in:
lib/updater/orm/mongo.rb

#initialize(hash = {}) ⇒ Mongo

Returns a new instance of Mongo.



12
13
14
15
16
17
18
19
20
21
# File 'lib/updater/orm/mongo.rb', line 12

def initialize(hash = {})
  @hash = {}
  hash.each do |key, val|
    if respond_to? "#{key}="
      send("#{key}=", val)
    else
      @hash[key] = val
    end
  end
end