Class: PostProxy::PaginatedResponse

Inherits:
ListResponse show all
Defined in:
lib/postproxy/types.rb

Instance Attribute Summary collapse

Attributes inherited from ListResponse

#data

Instance Method Summary collapse

Constructor Details

#initialize(data:, total:, page:, per_page:) ⇒ PaginatedResponse

Returns a new instance of PaginatedResponse.



324
325
326
327
328
329
# File 'lib/postproxy/types.rb', line 324

def initialize(data:, total:, page:, per_page:)
  super(data: data)
  @total = total
  @page = page
  @per_page = per_page
end

Instance Attribute Details

#pageObject (readonly)

Returns the value of attribute page.



322
323
324
# File 'lib/postproxy/types.rb', line 322

def page
  @page
end

#per_pageObject (readonly)

Returns the value of attribute per_page.



322
323
324
# File 'lib/postproxy/types.rb', line 322

def per_page
  @per_page
end

#totalObject (readonly)

Returns the value of attribute total.



322
323
324
# File 'lib/postproxy/types.rb', line 322

def total
  @total
end