vuderacha-activekv 0.0.1 → 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.
- data/Rakefile +1 -0
 - data/lib/activekv/base.rb +15 -0
 - metadata +12 -2
 
    
        data/Rakefile
    CHANGED
    
    | 
         @@ -47,6 +47,7 @@ begin 
     | 
|
| 
       47 
47 
     | 
    
         
             
              	s.files = %w(Rakefile README.rdoc) + Dir.glob("{bin,lib,spec}/**/*")
         
     | 
| 
       48 
48 
     | 
    
         
             
              	s.require_path = "lib"
         
     | 
| 
       49 
49 
     | 
    
         
             
              	s.add_dependency('activesupport', '>= 2.2.2')
         
     | 
| 
      
 50 
     | 
    
         
            +
              	s.add_dependency('wycats-moneta', '>= 0.5.0')
         
     | 
| 
       50 
51 
     | 
    
         
             
              end
         
     | 
| 
       51 
52 
     | 
    
         
             
            rescue LoadError
         
     | 
| 
       52 
53 
     | 
    
         
             
              puts "Jeweler not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
         
     | 
    
        data/lib/activekv/base.rb
    CHANGED
    
    | 
         @@ -148,3 +148,18 @@ module ActiveKV 
     | 
|
| 
       148 
148 
     | 
    
         
             
              class NoKeySpecifiedError < Exception
         
     | 
| 
       149 
149 
     | 
    
         
             
              end
         
     | 
| 
       150 
150 
     | 
    
         
             
            end
         
     | 
| 
      
 151 
     | 
    
         
            +
             
     | 
| 
      
 152 
     | 
    
         
            +
            # Patch to the Moneta datamapper class
         
     | 
| 
      
 153 
     | 
    
         
            +
            module Moneta
         
     | 
| 
      
 154 
     | 
    
         
            +
              class DataMapper
         
     | 
| 
      
 155 
     | 
    
         
            +
                def []=(key, value)
         
     | 
| 
      
 156 
     | 
    
         
            +
                  obj = @hash.get(key)
         
     | 
| 
      
 157 
     | 
    
         
            +
                  if obj
         
     | 
| 
      
 158 
     | 
    
         
            +
                    obj.value = value
         
     | 
| 
      
 159 
     | 
    
         
            +
                    obj.update
         
     | 
| 
      
 160 
     | 
    
         
            +
                  else
         
     | 
| 
      
 161 
     | 
    
         
            +
                    @hash.create(:the_key => key, :value => value)
         
     | 
| 
      
 162 
     | 
    
         
            +
                  end
         
     | 
| 
      
 163 
     | 
    
         
            +
                end
         
     | 
| 
      
 164 
     | 
    
         
            +
              end
         
     | 
| 
      
 165 
     | 
    
         
            +
            end
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification 
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: vuderacha-activekv
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version 
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.0. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.0.2
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors: 
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Paul Jones
         
     | 
| 
         @@ -9,7 +9,7 @@ autorequire: 
     | 
|
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
11 
     | 
    
         | 
| 
       12 
     | 
    
         
            -
            date: 2009-03- 
     | 
| 
      
 12 
     | 
    
         
            +
            date: 2009-03-23 00:00:00 -07:00
         
     | 
| 
       13 
13 
     | 
    
         
             
            default_executable: 
         
     | 
| 
       14 
14 
     | 
    
         
             
            dependencies: 
         
     | 
| 
       15 
15 
     | 
    
         
             
            - !ruby/object:Gem::Dependency 
         
     | 
| 
         @@ -22,6 +22,16 @@ dependencies: 
     | 
|
| 
       22 
22 
     | 
    
         
             
                  - !ruby/object:Gem::Version 
         
     | 
| 
       23 
23 
     | 
    
         
             
                    version: 2.2.2
         
     | 
| 
       24 
24 
     | 
    
         
             
                version: 
         
     | 
| 
      
 25 
     | 
    
         
            +
            - !ruby/object:Gem::Dependency 
         
     | 
| 
      
 26 
     | 
    
         
            +
              name: wycats-moneta
         
     | 
| 
      
 27 
     | 
    
         
            +
              type: :runtime
         
     | 
| 
      
 28 
     | 
    
         
            +
              version_requirement: 
         
     | 
| 
      
 29 
     | 
    
         
            +
              version_requirements: !ruby/object:Gem::Requirement 
         
     | 
| 
      
 30 
     | 
    
         
            +
                requirements: 
         
     | 
| 
      
 31 
     | 
    
         
            +
                - - ">="
         
     | 
| 
      
 32 
     | 
    
         
            +
                  - !ruby/object:Gem::Version 
         
     | 
| 
      
 33 
     | 
    
         
            +
                    version: 0.5.0
         
     | 
| 
      
 34 
     | 
    
         
            +
                version: 
         
     | 
| 
       25 
35 
     | 
    
         
             
            description: ActiveKV provides ActiveRecord style data storage for Key/Value stores.
         
     | 
| 
       26 
36 
     | 
    
         
             
            email: pauljones23@gmail.com
         
     | 
| 
       27 
37 
     | 
    
         
             
            executables: []
         
     |