Class: Core::Endpoint::BasicHandler::Paged::PagedTarget
- Inherits:
-
Object
- Object
- Core::Endpoint::BasicHandler::Paged::PagedTarget
- Defined in:
- app/api/core/endpoint/basic_handler/paged.rb
Defined Under Namespace
Classes: PageOfResults
Instance Method Summary collapse
-
#initialize(model) ⇒ PagedTarget
constructor
A new instance of PagedTarget.
- #paginate(options) ⇒ Object
Constructor Details
#initialize(model) ⇒ PagedTarget
Returns a new instance of PagedTarget.
58 59 60 |
# File 'app/api/core/endpoint/basic_handler/paged.rb', line 58 def initialize(model) @model = model end |
Instance Method Details
#paginate(options) ⇒ Object
81 82 83 |
# File 'app/api/core/endpoint/basic_handler/paged.rb', line 81 def paginate() PageOfResults.new([:page], [:total_entries], [:per_page]) end |