redis_obj 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 60078190708a0aa3872d0df60a6d389ab6949117
4
+ data.tar.gz: c88fb3d786df0eb865cdaf30816eada0b4315c8f
5
+ SHA512:
6
+ metadata.gz: 8304198906cc62aa89c17de1ee495d87c01f0f70569b548105a49195f68feb6b67c0d5d95e84dafc6dca7b770b15a1914f2a52c5bcb2dfd8ee4361d36a50dcef
7
+ data.tar.gz: 6d813e8d0144add088b84b744c0a6952c7d6ef717e2fe9e908190b3a48401c6663be400dc72af0449ab768b12c913975b535615b56d345ec1c3970e5518c1dc2
data/.gitignore ADDED
@@ -0,0 +1,17 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --color
2
+ --format progress
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in redis_obj.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Tal Atlas
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,29 @@
1
+ # RedisObj
2
+
3
+ TODO: Write a gem description
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ gem 'redis_obj'
10
+
11
+ And then execute:
12
+
13
+ $ bundle
14
+
15
+ Or install it yourself as:
16
+
17
+ $ gem install redis_obj
18
+
19
+ ## Usage
20
+
21
+ TODO: Write usage instructions here
22
+
23
+ ## Contributing
24
+
25
+ 1. Fork it
26
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
27
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
28
+ 4. Push to the branch (`git push origin my-new-feature`)
29
+ 5. Create new Pull Request
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,29 @@
1
+ class RedisObj::Base
2
+ attr_accessor :key, :redis
3
+ def initialize redis, key=nil
4
+ unless key
5
+ key = redis
6
+ redis = RedisObj.redis
7
+ end
8
+ @key = key
9
+ @redis = redis
10
+ end
11
+
12
+ def == other
13
+ self.class == other.class and self.key == other.key
14
+ end
15
+
16
+ def del_key
17
+ redis.del(key)
18
+ end
19
+
20
+ private
21
+
22
+ def get_keys(keys)
23
+ if keys.first.respond_to?(:key)
24
+ keys.collect(&:key)
25
+ else
26
+ keys
27
+ end
28
+ end
29
+ end
@@ -0,0 +1,69 @@
1
+ class RedisObj::Hash < RedisObj::Base
2
+ def del field
3
+ redis.hdel(key,field)
4
+ end
5
+
6
+ def incby field, amt
7
+ if amt.is_a?(Float)
8
+ redis.hincrbyfloat(key,field,amt)
9
+ else
10
+ redis.hincrby(key,field,amt)
11
+ end
12
+ end
13
+ alias incbyfloat incby
14
+
15
+ def inc field
16
+ incby(field,1)
17
+ end
18
+
19
+ def dec field
20
+ incby(field,-1)
21
+ end
22
+
23
+ def mget *fields
24
+ redis.hmget(key,*fields)
25
+ end
26
+
27
+ def mset *fields
28
+ redis.hmset(key,*fields)
29
+ end
30
+
31
+ def vals
32
+ redis.hvals(key)
33
+ end
34
+ alias values vals
35
+
36
+ def keys
37
+ redis.hkeys(key)
38
+ end
39
+
40
+ def exists field
41
+ redis.hexists(key,field)
42
+ end
43
+
44
+ def get field
45
+ redis.hget(key,field)
46
+ end
47
+ alias [] get
48
+
49
+ def set field, val
50
+ redis.hset(key,field,val)
51
+ end
52
+ alias []= set
53
+
54
+ def getall
55
+ redis.hgetall(key)
56
+ end
57
+ alias to_h getall
58
+
59
+ def len
60
+ redis.hlen(key)
61
+ end
62
+ alias size len
63
+ alias count len
64
+ alias length len
65
+
66
+ def setnx field, val
67
+ redis.hsetnx(key,field,val)
68
+ end
69
+ end
@@ -0,0 +1,89 @@
1
+ class RedisObj::List < RedisObj::Base
2
+ include Enumerable
3
+
4
+ def blpop *args
5
+ redis.blpop(key,*args)
6
+ end
7
+
8
+ def brpop *args
9
+ redis.brpop(key,*args)
10
+ end
11
+
12
+ def brpoplpush(destination, options = {})
13
+ redis.brpoplpush(key,destination,options)
14
+ end
15
+
16
+ def lindex(index)
17
+ redis.lindex(key,index)
18
+ end
19
+ alias [] lindex
20
+
21
+ def linsert(where, pivot, value)
22
+ redis.linsert(key,where,pivot,value)
23
+ end
24
+
25
+ def lrange(start, stop)
26
+ redis.lrange(key, start, stop)
27
+ end
28
+
29
+ def to_a
30
+ lrange(0,-1)
31
+ end
32
+
33
+ def each &blk
34
+ to_a.each(&blk)
35
+ end
36
+
37
+ def lrem(count, value)
38
+ redis.lrem(key, count, value)
39
+ end
40
+
41
+ def lset(index, value)
42
+ redis.lset(key, index, value)
43
+ end
44
+ alias []= lset
45
+
46
+ def ltrim(start, stop)
47
+ redis.ltrim(key, start, stop)
48
+ end
49
+
50
+ def len
51
+ redis.llen(key)
52
+ end
53
+ alias length len
54
+ alias size len
55
+ alias count len
56
+
57
+ def lpop
58
+ redis.lpop(key)
59
+ end
60
+ alias shift lpop
61
+
62
+ def lpush val
63
+ redis.lpush(val)
64
+ end
65
+ alias unshift lpush
66
+
67
+ def lpushx val
68
+ redis.lpushx(key,val)
69
+ end
70
+
71
+ def rpop
72
+ redis.rpop(key)
73
+ end
74
+ alias pop rpop
75
+
76
+ def rpoplpush destination
77
+ redis.rpoplpush(key, destination)
78
+ end
79
+
80
+ def rpush val
81
+ redis.rpush(key,val)
82
+ end
83
+ alias << rpush
84
+ alias push rpush
85
+
86
+ def rpushx val
87
+ redis.rpushx(key,val)
88
+ end
89
+ end
@@ -0,0 +1,84 @@
1
+ module RedisObj::Relations
2
+ module Initializers
3
+ def store_redis_in &blk
4
+ if blk
5
+ @store_redis_in = blk
6
+ else
7
+ @store_redis_in ||= begin
8
+ base_class = self.class.to_s.downcase
9
+ Proc.new { "#{base_class}:#{id}" }
10
+ end
11
+ end
12
+ end
13
+
14
+ def redis_prefix ctx
15
+ if ctx.is_a? ::Hash
16
+ ctx = OpenStruct.new(ctx)
17
+ end
18
+ ctx.instance_exec(&store_redis_in)
19
+ end
20
+
21
+ def redis_obj type, name, opts={}
22
+ opts[:key] = name unless opts.has_key?(:key)
23
+ opts[:redis] ||= -> { RedisObj.redis }
24
+
25
+ klass_method = "redis_#{name}"
26
+ instance_variable = "@#{name}"
27
+
28
+ define_method name do
29
+ unless obj = instance_variable_get(instance_variable)
30
+ obj = self.class.send(klass_method,self)
31
+
32
+ instance_variable_set(instance_variable,obj)
33
+ end
34
+ obj
35
+ end
36
+
37
+ define_singleton_method klass_method do |context|
38
+ redis = opts[:redis]
39
+
40
+ if redis.respond_to?(:call)
41
+ redis = redis.call
42
+ end
43
+
44
+ if opts[:key] == false
45
+ type.new(redis, "#{redis_prefix(context)}")
46
+ else
47
+ type.new(redis, "#{redis_prefix(context)}:#{opts[:key]}")
48
+ end
49
+ end
50
+ end
51
+
52
+ def redis_hash name, opts={}
53
+ redis_obj(RedisObj::Hash,name,opts)
54
+ end
55
+
56
+ def redis_set name, opts={}
57
+ redis_obj(RedisObj::Set,name,opts)
58
+ end
59
+
60
+ def redis_sorted_set name, opts={}
61
+ redis_obj(RedisObj::SortedSet,name,opts)
62
+ end
63
+
64
+ def redis_list name, opts={}
65
+ redis_obj(RedisObj::List,name,opts)
66
+ end
67
+
68
+ def inherited subklass
69
+ super
70
+ subklass.instance_variable_set(:@store_redis_in,@store_redis_in)
71
+ end
72
+ end
73
+
74
+ module InstanceMethods
75
+ def redis_prefix
76
+ self.class.redis_prefix(self)
77
+ end
78
+ end
79
+
80
+ def self.included klass
81
+ klass.extend Initializers
82
+ klass.send(:include, InstanceMethods)
83
+ end
84
+ end
@@ -0,0 +1,101 @@
1
+ class RedisObj::Set < RedisObj::Base
2
+ include Enumerable
3
+
4
+ def members
5
+ redis.smembers(key)
6
+ end
7
+ alias to_a members
8
+
9
+ def ismember val
10
+ redis.sismember(key,val)
11
+ end
12
+ alias include? ismember
13
+
14
+ def inter *keys
15
+ redis.sinter(key,*get_keys(keys))
16
+ end
17
+ alias & inter
18
+
19
+ def interstore destination, *keys
20
+ redis.sinterstore(destination,key,*get_keys(keys))
21
+ new_key = self.class.new(redis,destination)
22
+
23
+ if block_given?
24
+ begin
25
+ yield(new_key)
26
+ ensure
27
+ redis.del(destination)
28
+ end
29
+ end
30
+
31
+ new_key
32
+ end
33
+
34
+ def diff *keys
35
+ redis.sdiff(key,*get_keys(keys))
36
+ end
37
+ alias - diff
38
+
39
+ def diffstore destination, *keys
40
+ redis.sdiffstore(destination,key,*get_keys(keys))
41
+ new_key = self.class.new(redis,destination)
42
+
43
+ if block_given?
44
+ begin
45
+ yield(new_key)
46
+ ensure
47
+ redis.del(destination)
48
+ end
49
+ end
50
+
51
+ new_key
52
+ end
53
+
54
+ def union *keys
55
+ redis.sunion(key,*get_keys(keys))
56
+ end
57
+ alias | union
58
+
59
+ def unionstore destination, *keys
60
+ redis.sunionstore(destination,key,*get_keys(keys))
61
+ new_key = self.class.new(redis,destination)
62
+
63
+ if block_given?
64
+ begin
65
+ yield(new_key)
66
+ ensure
67
+ redis.del(destination)
68
+ end
69
+ end
70
+
71
+ new_key
72
+ end
73
+
74
+ def pop
75
+ redis.pop(key)
76
+ end
77
+
78
+ def add val
79
+ redis.sadd(key,val)
80
+ end
81
+ alias << add
82
+
83
+ def rem val
84
+ redis.srem(key,val)
85
+ end
86
+
87
+ def srandmember num=1
88
+ redis.srandmember(key,num)
89
+ end
90
+
91
+ def card
92
+ redis.scard(key)
93
+ end
94
+ alias length card
95
+ alias size card
96
+ alias count card
97
+
98
+ def each &blk
99
+ to_a.each(&blk)
100
+ end
101
+ end
@@ -0,0 +1,101 @@
1
+ class RedisObj::SortedSet < RedisObj::Base
2
+ def add score, member
3
+ redis.zadd(key,score,member)
4
+ end
5
+
6
+ def rem member
7
+ redis.zrem(key,mem)
8
+ end
9
+
10
+ def card min=0,max=0
11
+ if min
12
+ redis.zcount(key,min,max)
13
+ else
14
+ redis.zcard(key)
15
+ end
16
+ end
17
+ alias length card
18
+ alias size card
19
+ alias count card
20
+
21
+ def incby amt, member
22
+ redis.zincby(key,amt,member)
23
+ end
24
+
25
+ def inc member
26
+ incby(1,member)
27
+ end
28
+
29
+ def dec member
30
+ incby(-1,member)
31
+ end
32
+
33
+ def range start, stop, opts={}
34
+ redis.zrange(key,start,stop,opts)
35
+ end
36
+
37
+ def revrange start, stop, opts={}
38
+ redis.zrevrange(key,start,stop,opts)
39
+ end
40
+
41
+ def rangebyscore start, stop, opts={}
42
+ redis.zrangebyscore(key,start,stop,opts)
43
+ end
44
+
45
+ def revrangebyscore start, stop, opts={}
46
+ redis.zrevrangebyscore(key,start,stop,opts)
47
+ end
48
+
49
+ def rank mem
50
+ redis.rank(key,mem)
51
+ end
52
+
53
+ def revrank mem
54
+ redis.revrank(key,mem)
55
+ end
56
+
57
+ def remrangebyrank start, stop
58
+ redis.zremrangebyrank(key,start,stop)
59
+ end
60
+
61
+ def remrangebyscore start, stop
62
+ redis.zremrangebyscore(key,start,stop)
63
+ end
64
+
65
+ def interstore(destination, keys, options = {})
66
+ keys = [key]+keys
67
+
68
+ redis.zinterstore(destination,keys,options)
69
+
70
+ new_key = self.class.new(redis,destination)
71
+
72
+ if block_given?
73
+ begin
74
+ yield(new_key)
75
+ ensure
76
+ redis.del(destination)
77
+ end
78
+ end
79
+
80
+ new_key
81
+ end
82
+
83
+ def unionstore(destination, keys, options = {})
84
+ keys = [key]+keys
85
+
86
+ redis.zunionstore(destination,keys,options)
87
+
88
+ new_key = self.class.new(redis,destination)
89
+
90
+ if block_given?
91
+ begin
92
+ yield(new_key)
93
+ ensure
94
+ redis.del(destination)
95
+ end
96
+ end
97
+
98
+ new_key
99
+ end
100
+
101
+ end
@@ -0,0 +1,3 @@
1
+ module RedisObj
2
+ VERSION = "0.0.2"
3
+ end
data/lib/redis_obj.rb ADDED
@@ -0,0 +1,22 @@
1
+ require 'ostruct'
2
+
3
+ %w{
4
+ version
5
+ base
6
+ set
7
+ sorted_set
8
+ hash
9
+ relations
10
+ }.each do |f|
11
+ require "redis_obj/#{f}"
12
+ end
13
+
14
+ module RedisObj
15
+ class << self
16
+ attr_accessor :redis
17
+ end
18
+
19
+ def self.included reciever
20
+ raise NameError, "Please include RedisObj::Relations instead of this module"
21
+ end
22
+ end
data/redis_obj.gemspec ADDED
@@ -0,0 +1,26 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'redis_obj/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "redis_obj"
8
+ spec.version = RedisObj::VERSION
9
+ spec.authors = ["Tal Atlas"]
10
+ spec.email = ["me@tal.by"]
11
+ spec.description = %q{methods for managing redis keys in an object oriented manner}
12
+ spec.summary = %q{kinda like a redis ORM}
13
+ spec.homepage = "https://github.com/tal/redis_obj"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files`.split($/)
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_dependency 'redis'
22
+
23
+ spec.add_development_dependency "bundler", "~> 1.3"
24
+ spec.add_development_dependency "rake"
25
+ spec.add_development_dependency "rspec"
26
+ end
@@ -0,0 +1,37 @@
1
+ require 'spec_helper'
2
+
3
+ describe RedisObj do
4
+ let(:test_klass) do
5
+ Class.new do
6
+ attr_reader :id
7
+ include RedisObj::Relations
8
+
9
+ redis_set :friends
10
+
11
+ def initialize
12
+ @id = rand(100000)
13
+ end
14
+ end
15
+ end
16
+ subject {test_klass}
17
+
18
+ describe "redis_obj" do
19
+ let(:context) {test_klass.new}
20
+ subject {test_klass.redis_friends(context)}
21
+
22
+ it {should be_a(RedisObj::Set)}
23
+ its(:key) {should == "class:#{context.id}:friends"}
24
+
25
+ context "hash" do
26
+ let(:context) {{id: rand(100000)}}
27
+ # before {context.should_receive(:is_a?).and_return(true)}
28
+
29
+ it do
30
+ test_klass.redis_prefix(context).should == "class:#{context[:id]}"
31
+ end
32
+
33
+ it {should be_a(RedisObj::Set)}
34
+ its(:key) {should == "class:#{context[:id]}:friends"}
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,107 @@
1
+ require 'spec_helper'
2
+
3
+ describe RedisObj do
4
+ let(:base_redis) { mock("BaseRedis") }
5
+ before { RedisObj.redis = base_redis }
6
+
7
+ let(:test_klass) do
8
+ Class.new do
9
+ attr_reader :id
10
+ include RedisObj::Relations
11
+
12
+ def initialize
13
+ @id = rand(100000)
14
+ end
15
+ end
16
+ end
17
+
18
+ context 'custom class' do
19
+ it "should store the" do
20
+ test_klass.should respond_to(:store_redis_in)
21
+ blk = -> { 'foo' }
22
+ test_klass.store_redis_in(&blk)
23
+ test_klass.store_redis_in.should == blk
24
+ end
25
+
26
+ it "should set default prefix" do
27
+ test_klass.new.redis_prefix.should start_with('class:')
28
+ end
29
+ end
30
+
31
+ let(:obj) {test_klass.new}
32
+ subject {obj}
33
+
34
+ context 'with prefix' do
35
+ before { test_klass.store_redis_in { "test:#{id}"} }
36
+ its(:redis_prefix) { should == "test:#{subject.id}" }
37
+
38
+ describe "global redis instance" do
39
+ subject{obj.friends}
40
+ let(:redis) {mock('Redis')}
41
+
42
+ before { RedisObj.redis = redis; test_klass.redis_set :friends }
43
+ after { RedisObj.redis = base_redis }
44
+
45
+ it { RedisObj.redis.should === redis }
46
+
47
+ its(:redis) { should === redis }
48
+ end
49
+
50
+ describe 'redis_hash with no key' do
51
+ before do
52
+ test_klass.redis_hash :hash, key: false
53
+ end
54
+
55
+ it {should respond_to :hash}
56
+ its(:hash) { should be_a(RedisObj::Hash) }
57
+
58
+ describe 'hash' do
59
+ subject { obj.hash }
60
+
61
+ its(:key) { should == obj.redis_prefix }
62
+ end
63
+ end
64
+
65
+ describe 'redis_set defined default key' do
66
+ let(:redis) {mock('Redis')}
67
+ before do
68
+ test_klass.redis_set :friends
69
+ test_klass.redis_set :friends2, key: 'f', redis: redis
70
+ test_klass.redis_set :friends3, key: 'ff', redis: ->{redis}
71
+ end
72
+
73
+ it {should respond_to :friends}
74
+ its(:friends) { should be_a(RedisObj::Set) }
75
+
76
+ it 'should memoize' do
77
+ f = obj.friends
78
+ obj.friends.should be f
79
+ obj.friends.should be f
80
+ obj.instance_variable_set(:@friends,nil)
81
+ obj.friends.should_not be f
82
+ end
83
+
84
+ describe 'friends' do
85
+ subject{obj.friends}
86
+
87
+ its(:key) { should == "test:#{obj.id}:friends" }
88
+ its(:redis) { should === base_redis}
89
+
90
+ it { RedisObj.redis.should === base_redis }
91
+ end
92
+
93
+ describe 'friends2' do
94
+ subject{obj.friends2}
95
+
96
+ its(:key) { should == "test:#{obj.id}:f" }
97
+ its(:redis) { should be redis }
98
+ end
99
+
100
+ describe 'friends3' do
101
+ subject{obj.friends3}
102
+
103
+ its(:redis) { should be redis }
104
+ end
105
+ end
106
+ end
107
+ end
@@ -0,0 +1,22 @@
1
+ # This file was generated by the `rspec --init` command. Conventionally, all
2
+ # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
3
+ # Require this file using `require "spec_helper"` to ensure that it is only
4
+ # loaded once.
5
+ #
6
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
7
+ RSpec.configure do |config|
8
+ config.treat_symbols_as_metadata_keys_with_true_values = true
9
+ config.run_all_when_everything_filtered = true
10
+ config.filter_run :focus
11
+
12
+ # Run specs in random order to surface order dependencies. If you find an
13
+ # order dependency and want to debug it, you can fix the order by providing
14
+ # the seed, which is printed after each run.
15
+ # --seed 1234
16
+ config.order = 'random'
17
+ end
18
+
19
+ $:.unshift(File.expand_path(File.join(File.dirname(__FILE__),'..','lib')))
20
+
21
+ require 'redis'
22
+ require 'redis_obj'
metadata ADDED
@@ -0,0 +1,121 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: redis_obj
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.2
5
+ platform: ruby
6
+ authors:
7
+ - Tal Atlas
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2013-06-06 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: redis
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - '>='
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - '>='
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ~>
32
+ - !ruby/object:Gem::Version
33
+ version: '1.3'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ~>
39
+ - !ruby/object:Gem::Version
40
+ version: '1.3'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - '>='
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - '>='
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rspec
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - '>='
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ description: methods for managing redis keys in an object oriented manner
70
+ email:
71
+ - me@tal.by
72
+ executables: []
73
+ extensions: []
74
+ extra_rdoc_files: []
75
+ files:
76
+ - .gitignore
77
+ - .rspec
78
+ - Gemfile
79
+ - LICENSE.txt
80
+ - README.md
81
+ - Rakefile
82
+ - lib/redis_obj.rb
83
+ - lib/redis_obj/base.rb
84
+ - lib/redis_obj/hash.rb
85
+ - lib/redis_obj/list.rb
86
+ - lib/redis_obj/relations.rb
87
+ - lib/redis_obj/set.rb
88
+ - lib/redis_obj/sorted_set.rb
89
+ - lib/redis_obj/version.rb
90
+ - redis_obj.gemspec
91
+ - spec/redis_obj_class_methods_spec.rb
92
+ - spec/redis_obj_spec.rb
93
+ - spec/spec_helper.rb
94
+ homepage: https://github.com/tal/redis_obj
95
+ licenses:
96
+ - MIT
97
+ metadata: {}
98
+ post_install_message:
99
+ rdoc_options: []
100
+ require_paths:
101
+ - lib
102
+ required_ruby_version: !ruby/object:Gem::Requirement
103
+ requirements:
104
+ - - '>='
105
+ - !ruby/object:Gem::Version
106
+ version: '0'
107
+ required_rubygems_version: !ruby/object:Gem::Requirement
108
+ requirements:
109
+ - - '>='
110
+ - !ruby/object:Gem::Version
111
+ version: '0'
112
+ requirements: []
113
+ rubyforge_project:
114
+ rubygems_version: 2.0.3
115
+ signing_key:
116
+ specification_version: 4
117
+ summary: kinda like a redis ORM
118
+ test_files:
119
+ - spec/redis_obj_class_methods_spec.rb
120
+ - spec/redis_obj_spec.rb
121
+ - spec/spec_helper.rb