class Bitly::API::List

A base class for lists of API resources. Implements Enumerable.

Attributes

response[R]

Public Class Methods

new(items:, response:) click to toggle source
# File lib/bitly/api/list.rb, line 12
def initialize(items:, response:)
  @items = items
  @response = response
end

Public Instance Methods

each() { |item| ... } click to toggle source
# File lib/bitly/api/list.rb, line 17
def each
  @items.each { |item| yield item }
end