Grabs a URL from DATA_FEED_URLS and formats it appropriately.
 @param data_name [Symbol]
 @param next_data_indices [Symbol] query parameters to get the next set of data
773426
def get_url(data_name, next_data_indices = {})
      if next_data_indices.empty?
        next_data_indices = { nextStartIndex: 0, nextLikeStartIndex: 0, nextThumbStartIndex: 0 }
      else
        next_data_indices = next_data_indices.dup
      end

      next_data_indices[:webname] = @webname
      next_data_indices[:pat] = Downloader.get_pat

      DATA_FEED_URLS[data_name] % next_data_indices
    end
647195
function (next) {

      var app = connect();

      // application/json
      app.use(bodyParser.json());

      // application/x-www-form-urlencoded
      app.use(bodyParser.urlencoded({ extended: false }));

      // url parameters
      app.use(function (req, res, next) {
        if (!req.query) {
          req.query = ~req.url.indexOf('?')
            ? qs.parse(parseUrl(req).query)
            : {};
        }

        req.params = _.merge({}, req.query, req.body);

        next();
      });

      next(null, app);
    }
181930
function Link(name, data, prev, next) {

    /**
     * @public
     * @memberOf {Link}
     * @property
     * @type {String}
     * */
    this.name = name;

    /**
     * @public
     * @memberOf {Link}
     * @property
     * @type {Link}
     * */
    this.prev = prev;

    /**
     * @public
     * @memberOf {Link}
     * @property
     * @type {Link}
     * */
    this.next = next;

    /**
     * @public
     * @memberOf {Link}
     * @property
     * @type {*}
     * */
    this.data = data;
}
918545
def _get(self, *args, **kwargs):
        """"""
        prev_data = kwargs.pop('prev_data', [])
        resp = self._request('get', *args, **kwargs)
        resp_content = resp._content
        if not resp_content:
            # No content so its obviously not paginated
            return resp

        # if resp._content is a bytes object, decode it so we can loads it as json
        if isinstance(resp_content, bytes):
            resp_content = resp_content.decode('utf-8')

        # Load the json so we can use the data as python objects
        content = json.loads(resp_content)
        if 'pagination' not in content:
            # Result is not paginated
            return resp

        page_info = content['pagination']
        if not page_info['next_uri']:
            # next_uri is None when the cursor has been iterated to the last element
            content['data'].extend(prev_data)
            # If resp._content was is a bytes object, only set it as a bytes object
            if isinstance(resp_content, bytes):
                resp._content = json.dumps(content).decode('utf-8')
            else:
                resp._content = json.dumps(content)
            return resp

        prev_data.extend(content['data'])
        next_page_id = page_info['next_uri'].split('=')[-1]
        kwargs.update({
            'prev_data': prev_data,
            'params': {'starting_after': next_page_id}
        })
        return self._get(*args, **kwargs)
906079
def fetch_data(self, **var):
        """"""
        varstr = ','.join(name + self._convert_indices(ind)
                          for name, ind in var.items())
        query = self.query().add_query_parameter(req='data', var=varstr)
        return self._fetch(query)
261526
protected String getNextUrl() {
		String url = urls.get(currentIndex);
		currentIndex = (currentIndex + 1) % urls.size();
		return url;
	}
69367
function getNextPageUrl(response) {
  const link = response.headers.get('link');
  if (!link) {
    return null;
  }

  const nextLink = link.split(',').filter(s => s.indexOf('rel="next"') > -1)[0];
  if (!nextLink) {
    return null;
  }

  return nextLink.split(';')[0].slice(1, -1);
}
460016
def results(self, dataset_name, index_by, timeframe):
        
        url = "{0}/{1}/results".format(self._cached_datasets_url, dataset_name)

        index_by = index_by if isinstance(index_by, str) else json.dumps(index_by)
        timeframe = timeframe if isinstance(timeframe, str) else json.dumps(timeframe)

        query_params = {
            "index_by": index_by,
            "timeframe": timeframe
        }

        return self._get_json(
            HTTPMethods.GET, url, self._get_read_key(), params=query_params
        )
149226
def get(self, url, data=None, params=None):
        
        return self.request("get", url, data, params)
778499
def get_next(object_list)
      varbind_list = @mib.varbind_list(object_list, :NullValue)
      request = GetNextRequest.new(@@request_id.next, varbind_list)
      try_request(request)
    end
298692
@Trivial
    private String getNextURL(String currentURL) {
        List<String> urlList = getEnvURLList();
        int urlIndex = getURLIndex(currentURL, urlList);
        return urlList.get((urlIndex + 1) % urlList.size());
    }
1285345
def get_next_redirect_url(request, redirect_field_name="next"):
    
    redirect_to = get_request_param(request, redirect_field_name)
    if not get_adapter(request).is_safe_url(redirect_to):
        redirect_to = None
    return redirect_to
697793
def get_index_pages(original_url, pagination_index, pagination_interval, options={})
      resps = []
      prev_url = nil
      while resps.empty? || !resps.last.empty?
        next_url = self.next_index_page_url(original_url, pagination_index)
        break if next_url.empty?
        
        next_url = resolve_url(next_url, original_url)
        break if next_url == prev_url

        next_resp = self.get_page(next_url, @index_debug, options).to_s
        prev_url = next_url
        pagination_index += pagination_interval
        resps << next_resp
      end
      resps
    end
225654
def _set_query_data(self, action='query'):
        
        data = self._load_response(action)
        page = data['query']['pages'][0]

        self._handle_continuations(data, action)

        if action == 'query':
            self.data['random'] = data['query']['random'][0]["title"]

        self._extend_data('backlinks', data['query'].get('backlinks'))

        self.data['redirected'] = data['query'].get('redirects')

        self._set_query_data_fast_1(page)  # avoid pylint too-many-branches
        self._set_query_data_fast_2(page)
        self._set_query_data_slow(page)
528985
def get_paginated_response(self, data):
        
        return Response({
            'next': self.get_next_link(),
            'previous': self.get_previous_link(),
            'count': self.page.paginator.count,
            'num_pages': self.page.paginator.num_pages,
            'current_page': self.page.number,
            'start': (self.page.number - 1) * self.get_page_size(self.request),
            'results': data
        })
1041282
public function getNextLinkQueryStringParams()
    {
        $nextLink = $this->getNextLink();
        if (!isset($nextLink)) {
            throw new \Exception('No HATEOAS \"next\" link provided.');
        }
        $parsedUrl = parse_url($nextLink->getUrl());
        $qsArray = [];
        parse_str($parsedUrl['query'], $qsArray);
        return $qsArray;
    }
907848
def get_all_connections(self, id, connection_name, **args):
        
        while True:
            page = self.get_connections(id, connection_name, **args)
            for post in page["data"]:
                yield post
            next = page.get("paging", {}).get("next")
            if not next:
                return
            args = parse_qs(urlparse(next).query)
            del args["access_token"]