Class: DHS::Pagination::TotalPages
- Defined in:
- lib/dhs/pagination/total_pages.rb
Constant Summary
Constants inherited from Page
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
- #total ⇒ Object (also: #count)
Methods inherited from Page
#current_page, #next_offset, next_offset
Methods inherited from Base
#current_page, #first_page, #initialize, #last_page, #limit, #limit_value, #next?, #next_offset, #next_page, #offset, page_to_offset, #pages_left, #pages_left?, #parallel?, #prev_page, #previous?, #total_pages
Constructor Details
This class inherits a constructor from DHS::Pagination::Base
Instance Method Details
#total ⇒ Object Also known as: count
5 6 7 |
# File 'lib/dhs/pagination/total_pages.rb', line 5 def total (data._raw.dig(*_record.total_key) || 0) * limit end |