Class: BOSSMan::Search

Inherits:
Object
  • Object
show all
Defined in:
lib/bossman/search.rb

Constant Summary collapse

DEFAULT_COUNT =
10
DEFAULT_START =
0
VALID_METHODS =
[:web, :images, :news, :spelling, :se_inlink, :se_pagedata]

Class Method Summary collapse

Class Method Details

.method_missing(*args) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/bossman/search.rb', line 8

def method_missing(*args)
  method, query, options = args
  super unless VALID_METHODS.include?(method)
  options = {} if options.nil?
  boss = BOSS.new(method, query, options_defaults.merge(options))
  boss.get
end