Module: BingSearchClient

Defined in:
lib/bing_search_client.rb,
lib/bing_search_client/news.rb,
lib/bing_search_client/client.rb,
lib/bing_search_client/result.rb,
lib/bing_search_client/version.rb

Overview

TODO implement client for Web, Image and Video search

Defined Under Namespace

Classes: BadResponse, Client, Configuration, News, Result

Constant Summary collapse

VERSION =
"0.1.1"

Class Method Summary collapse

Class Method Details

.configObject

Return configuration parameters

Examples:

BingSearchClient.config.api_key


25
26
27
# File 'lib/bing_search_client.rb', line 25

def self.config
  @config
end

.configure {|@config ||= Configuration.new| ... } ⇒ Object

Class method to set up configuration parameters

Examples:

BingSearchClient.configure do |c|
  c. = "123"
end

Yields:



16
17
18
# File 'lib/bing_search_client.rb', line 16

def self.configure(&block)
  yield @config ||= Configuration.new
end

.reset_configObject

Reset configuration parameters

Examples:

BingSearchClient.reset_config


34
35
36
# File 'lib/bing_search_client.rb', line 34

def self.reset_config
  @config = nil
end