class DHS::Pagination::Page
Constants
- DEFAULT_OFFSET
Public Class Methods
next_offset(current_page, _limit, step = 1)
click to toggle source
# File lib/dhs/pagination/page.rb, line 15 def self.next_offset(current_page, _limit, step = 1) current_page.to_i + step.to_i end
Public Instance Methods
current_page()
click to toggle source
# File lib/dhs/pagination/page.rb, line 7 def current_page offset end
next_offset(step = 1)
click to toggle source
# File lib/dhs/pagination/page.rb, line 11 def next_offset(step = 1) self.class.next_offset(current_page, limit, step) end