kongkit 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 42dfc3065e9521b0e161616a829a71ae11378f95
4
- data.tar.gz: cdc11c8200d35335ac94184577f525ce92491d73
3
+ metadata.gz: 3ac2d8acd874c49c8f51d2ee7cfebf7d695839be
4
+ data.tar.gz: a8d7a6106ab1c094de1a22315a9079fd2dc76cf7
5
5
  SHA512:
6
- metadata.gz: 8698006c47bb40e92bdf0ab54553881071c008571ff578afea3bd0989593e6b6941a516ba2e1bbe8f48748748396c064f1f9a59e6f77f4342665a6642f259ff9
7
- data.tar.gz: 833f237ceeb37b5e23601e01b90bd343b559855cc2df3f2c07ec072e6bfb34b15692b83cd9b2455056397f011ee498340941b6a13843a3f2ba4d642d7f23cf39
6
+ metadata.gz: ca8d5fbc0ee6d7a7d5c01cf5b122a01ffd2c9e252849c0ca769e4880f468033410ebc512bb3dd9f1610b786ea67d5e22e737a11243b63b15d962ca784e34884e
7
+ data.tar.gz: 4313e4706c4313182c02d278ae189091ad853803f3f6985e1ba9b0cabbe90c9543fcea2650bdd576658ec4f004d5f50f3c8249995a0867ab4acf32626de14769
@@ -1,6 +1,8 @@
1
1
  module Kongkit
2
2
  class Client
3
3
  class Resource
4
+ include Enumerable
5
+
4
6
  def initialize(client, data, status_code)
5
7
  @client = client
6
8
  @data = data
@@ -17,6 +19,13 @@ module Kongkit
17
19
  nil
18
20
  end
19
21
 
22
+ # Calls block once for each key in the data hash, passing the key-value pair as parameters
23
+ #
24
+ # @return [Enumerator] Enumerator
25
+ def each(&block)
26
+ data.each(&block)
27
+ end
28
+
20
29
  # Retrieves the next resource
21
30
  #
22
31
  # @return [Kongkit::Client::Resource] Resource
@@ -1,3 +1,3 @@
1
1
  module Kongkit
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kongkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fabian Mettler