Class: PostProxy::PaginatedResponse
- Inherits:
-
ListResponse
- Object
- ListResponse
- PostProxy::PaginatedResponse
- Defined in:
- lib/postproxy/types.rb
Instance Attribute Summary collapse
-
#page ⇒ Object
readonly
Returns the value of attribute page.
-
#per_page ⇒ Object
readonly
Returns the value of attribute per_page.
-
#total ⇒ Object
readonly
Returns the value of attribute total.
Attributes inherited from ListResponse
Instance Method Summary collapse
-
#initialize(data:, total:, page:, per_page:) ⇒ PaginatedResponse
constructor
A new instance of PaginatedResponse.
Constructor Details
#initialize(data:, total:, page:, per_page:) ⇒ PaginatedResponse
Returns a new instance of PaginatedResponse.
174 175 176 177 178 179 |
# File 'lib/postproxy/types.rb', line 174 def initialize(data:, total:, page:, per_page:) super(data: data) @total = total @page = page @per_page = per_page end |
Instance Attribute Details
#page ⇒ Object (readonly)
Returns the value of attribute page.
172 173 174 |
# File 'lib/postproxy/types.rb', line 172 def page @page end |
#per_page ⇒ Object (readonly)
Returns the value of attribute per_page.
172 173 174 |
# File 'lib/postproxy/types.rb', line 172 def per_page @per_page end |
#total ⇒ Object (readonly)
Returns the value of attribute total.
172 173 174 |
# File 'lib/postproxy/types.rb', line 172 def total @total end |