Class: Aqua::Storage

  • Mash
    • Aqua::Storage

Storage

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

public method_missing(method, *args)

auto loads the default store to CouchDB if Store is used without Aqua configuration of a store

[View source]


50
51
52
53
54
55
56
57
# File 'lib/aqua/store/storage.rb', line 50

def method_missing( method, *args )
  if respond_to?( :commit ) 
    raise NoMethodError
  else
    Aqua.set_storage_engine # to default, currently CouchDB   
    send( method.to_sym, eval(args.map{|value| "'#{value}'"}.join(', ')) ) # resend!
  end  
end
Generated on Friday, August 21 2009 at 12:48:50 PM by YARD 0.2.3.5 (ruby-1.8.6).