Class: CouchRest::Model::SearchResults
- Inherits:
-
Object
- Object
- CouchRest::Model::SearchResults
- Includes:
- Enumerable
- Defined in:
- lib/couchrest_model_cloudant.rb
Instance Attribute Summary collapse
-
#bookmark ⇒ Object
Returns the value of attribute bookmark.
-
#total_rows ⇒ Object
Returns the value of attribute total_rows.
Instance Method Summary collapse
- #each ⇒ Object
-
#initialize(total_rows, bookmark, objects) ⇒ SearchResults
constructor
A new instance of SearchResults.
Constructor Details
#initialize(total_rows, bookmark, objects) ⇒ SearchResults
Returns a new instance of SearchResults.
29 30 31 32 33 |
# File 'lib/couchrest_model_cloudant.rb', line 29 def initialize(total_rows, bookmark, objects) @total_rows = total_rows @bookmark = bookmark @objects = objects end |
Instance Attribute Details
#bookmark ⇒ Object
Returns the value of attribute bookmark.
27 28 29 |
# File 'lib/couchrest_model_cloudant.rb', line 27 def bookmark @bookmark end |
#total_rows ⇒ Object
Returns the value of attribute total_rows.
27 28 29 |
# File 'lib/couchrest_model_cloudant.rb', line 27 def total_rows @total_rows end |
Instance Method Details
#each ⇒ Object
35 36 37 38 39 |
# File 'lib/couchrest_model_cloudant.rb', line 35 def each @objects.each do |member| yield member end end |