Class: PayPal::SDK::Subscriptions::Plan::Page

Inherits:
RequestBase show all
Defined in:
lib/paypal-sdk/subscriptions/plan.rb

Instance Attribute Summary

Attributes inherited from RequestAPIBase

#error, #header, #request_id

Instance Method Summary collapse

Methods inherited from RequestBase

#commit, #create, create!, find, #path, #update

Methods inherited from RequestAPIBase

#http_header, #merge!, #raise_error!, raise_on_api_error, #success?

Methods included from RequestDataType

#api, api, #error=, included

Instance Method Details

#nextObject



69
70
71
72
73
74
75
76
# File 'lib/paypal-sdk/subscriptions/plan.rb', line 69

def next
  link = links.detect { |l| l.rel == 'next' }
  if link
    uri = URI.parse(link.href)
    response = api.api_call(method: :get, uri: uri, header: {})
    self.class.new(response)
  end
end