mini_cache 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: d667eb0ee357eea898da78996e2641164ee66c6c
4
+ data.tar.gz: 5d8daab29c61434ccc298f59e2c313507be4d181
5
+ SHA512:
6
+ metadata.gz: 2de1d028b8ea353425e84e971e2fb572f69dc95748d8a7fafde1513d5d5b37d67afbb454fa0fe1074c4551fbf820c1dec06382d8df70c5a360ebf6eeee457f1e
7
+ data.tar.gz: 0d932bf0b9ff36e6252ea4e452da53ea56d6fc844066e024880b548e06cae39e16f1061742d2c0a3ddbfa9fb821460fdba11a1e139d194b64489c983ebd1c616
data/README.md CHANGED
@@ -1,8 +1,10 @@
1
1
  # MiniCache
2
2
 
3
3
  MiniCache is a lightweight in-memory key-value store for Ruby objects.
4
- This gem has no external dependencies and can be used in a Ruby project
5
- (including Rails apps).
4
+ This gem has no external dependencies and has been tested in MRI 1.9.x and
5
+ JRuby 1.9 mode.
6
+
7
+ Extracted from [Leadscreener](http://www.leadscreener.com/).
6
8
 
7
9
  ## Motivation
8
10
 
@@ -1,11 +1,11 @@
1
1
  module MiniCache
2
2
  class Store
3
3
  include Enumerable
4
-
4
+
5
5
  # Public: Returns the hash of key-value pairs.
6
6
  attr_reader :data
7
7
 
8
- # Public: Initializes a new TinyCache object.
8
+ # Public: Initializes a new MiniCache object.
9
9
  #
10
10
  # data - A Hash of key-value pairs (optional).
11
11
  #
@@ -100,7 +100,7 @@ module MiniCache
100
100
  check_key!(key)
101
101
  @data.delete(key.to_s)
102
102
  end
103
-
103
+
104
104
  # Public: Clears all key-value pairs.
105
105
  #
106
106
  # Returns nothing.
@@ -117,7 +117,7 @@ module MiniCache
117
117
  def each(&block)
118
118
  @data.each { |k, v| yield(k, v) }
119
119
  end
120
-
120
+
121
121
  # Public: Loads a hash of data into the cache.
122
122
  #
123
123
  # data - A Hash of data with either String or Symbol keys.
@@ -129,9 +129,9 @@ module MiniCache
129
129
  @data[key.to_s] = value
130
130
  end
131
131
  end
132
-
132
+
133
133
  private
134
-
134
+
135
135
  # Internal: Raises an error if the key is not a String
136
136
  # or a Symbol.
137
137
  #
@@ -142,4 +142,4 @@ module MiniCache
142
142
  end
143
143
  end
144
144
  end
145
- end
145
+ end
@@ -1,3 +1,3 @@
1
1
  module MiniCache
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,38 +1,36 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: mini_cache
3
- version: !ruby/object:Gem::Version
4
- prerelease:
5
- version: 1.0.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.1
6
5
  platform: ruby
7
- authors:
6
+ authors:
8
7
  - Derrick Reimer
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
-
13
- date: 2012-07-21 00:00:00 Z
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
11
+ date: 2015-12-10 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
16
14
  name: shoulda-context
17
- prerelease: false
18
- requirement: &id001 !ruby/object:Gem::Requirement
19
- none: false
20
- requirements:
21
- - - ">="
22
- - !ruby/object:Gem::Version
23
- version: "0"
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - '>='
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
24
20
  type: :development
25
- version_requirements: *id001
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - '>='
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
26
27
  description: A lightweight, in-memory cache for Ruby objects
27
- email:
28
+ email:
28
29
  - derrickreimer@gmail.com
29
30
  executables: []
30
-
31
31
  extensions: []
32
-
33
32
  extra_rdoc_files: []
34
-
35
- files:
33
+ files:
36
34
  - .gitignore
37
35
  - Gemfile
38
36
  - LICENSE
@@ -46,31 +44,28 @@ files:
46
44
  - test/test_helper.rb
47
45
  homepage: https://github.com/djreimer/mini_cache
48
46
  licenses: []
49
-
47
+ metadata: {}
50
48
  post_install_message:
51
49
  rdoc_options: []
52
-
53
- require_paths:
50
+ require_paths:
54
51
  - lib
55
- required_ruby_version: !ruby/object:Gem::Requirement
56
- none: false
57
- requirements:
58
- - - ">="
59
- - !ruby/object:Gem::Version
60
- version: "0"
61
- required_rubygems_version: !ruby/object:Gem::Requirement
62
- none: false
63
- requirements:
64
- - - ">="
65
- - !ruby/object:Gem::Version
66
- version: "0"
52
+ required_ruby_version: !ruby/object:Gem::Requirement
53
+ requirements:
54
+ - - '>='
55
+ - !ruby/object:Gem::Version
56
+ version: '0'
57
+ required_rubygems_version: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
67
62
  requirements: []
68
-
69
63
  rubyforge_project:
70
- rubygems_version: 1.8.24
64
+ rubygems_version: 2.3.0
71
65
  signing_key:
72
- specification_version: 3
66
+ specification_version: 4
73
67
  summary: MiniCache is a lightweight, in-memory key-value store for Ruby objects
74
- test_files:
68
+ test_files:
75
69
  - test/mini_cache/store_test.rb
76
70
  - test/test_helper.rb
71
+ has_rdoc: