Sha256: 5f0236058db815e0d022bc000a3ce246a1e45b6977c7aa1090f10de8604a3f3e
Contents?: true
Size: 699 Bytes
Versions: 14
Compression:
Stored size: 699 Bytes
Contents
module Clever module APIOperations # Represents a list of results for a paged request. class ResultsList include Enumerable # Create a results list from a PageList # @api private # @return [ResultsList] def initialize(pagelist) @pages = pagelist end # Iterate over results list # @api public # @return [nil] # @example # results = Clever::District.find # returns a ResultsList # results.each do |district| # puts district.name # end def each @pages.each do |page| page.each do |elem| yield elem end end end end end end
Version data entries
14 entries across 14 versions & 1 rubygems