A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://rubydoc.info/github/piotrmurach/github/master/Github/PagedRequest below:

PagedRequest – Documentation for piotrmurach/github (master) – RubyDoc.info

Module: Github::PagedRequest Overview

A module that adds http get request to response pagination

Constant Summary collapse
FIRST_PAGE =

Default request page if none provided

1
PER_PAGE =

Default number of items as specified by API

30
NOT_FOUND =

Either page or per_page parameter not present

-1 
Constants included from Constants

Constants::ACCEPT, Constants::ACCEPTED_OAUTH_SCOPES, Constants::ACCEPT_CHARSET, Constants::CACHE_CONTROL, Constants::CONTENT_LENGTH, Constants::CONTENT_TYPE, Constants::DATE, Constants::ETAG, Constants::HEADER_LAST, Constants::HEADER_LINK, Constants::HEADER_NEXT, Constants::LOCATION, Constants::META_FIRST, Constants::META_LAST, Constants::META_NEXT, Constants::META_PREV, Constants::META_REL, Constants::OAUTH_SCOPES, Constants::PARAM_PAGE, Constants::PARAM_PER_PAGE, Constants::PARAM_START_PAGE, Constants::RATELIMIT_LIMIT, Constants::RATELIMIT_REMAINING, Constants::RATELIMIT_RESET, Constants::SERVER, Constants::USER_AGENT

Instance Method Summary collapse Instance Method Details #default_page ⇒ Object
24
25
26
# File 'lib/github_api/paged_request.rb', line 24

def default_page
  current_api.page ? current_api.page : FIRST_PAGE
end
#default_page_size ⇒ Object

Check if current api instance has default per_page param set, otherwise use global default.

20
21
22
# File 'lib/github_api/paged_request.rb', line 20

def default_page_size
  current_api.per_page ? current_api.per_page : PER_PAGE
end
#page_request(path, params = {}) ⇒ Object

Perform http get request with pagination parameters


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4