Class: OpenSearch::OpenSearch10
- Inherits:
-
OpenSearchBase
- Object
- OpenSearchBase
- OpenSearch::OpenSearch10
- Defined in:
- lib/opensearch/1.0.rb
Constant Summary collapse
- Nodes =
%w(url format short_name long_name description tags image sample_search developer contact attribution syndication_right adult_content)
- Pagers =
{ "count" => 20, "start_index" => 1, "start_page" => 1 }
Instance Method Summary collapse
-
#initialize(doc) ⇒ OpenSearch10
constructor
A new instance of OpenSearch10.
- #search(query) ⇒ Object
Constructor Details
#initialize(doc) ⇒ OpenSearch10
Returns a new instance of OpenSearch10.
12 13 14 15 16 |
# File 'lib/opensearch/1.0.rb', line 12 def initialize(doc) @description = Hash.new @pager = Pagers.dup super end |
Instance Method Details
#search(query) ⇒ Object
18 19 20 21 22 |
# File 'lib/opensearch/1.0.rb', line 18 def search(query) url = @description["url"] rss = super(url, query) parse_rss(rss) end |