Cache class that uses {Ramaze::LRUHash} as a storage engine. This cache has the advantage that unlike Innate::Cache::Memory it does not leak memory over time when using the cache for sessions.
@example
Ramaze::Cache.options.session = Ramaze::Cache::LRU Ramaze.setup_dependencies
@author Michael Fellinger @since 17-07-2009
Hash containing all the options for the cache.
Clears the entire cache.
@author Michael Fellinger @since 17-07-2009
# File lib/ramaze/cache/lru.rb, line 50 50: def cache_clear 51: @store.clear 52: end
Deletes a set of data from the cache
@author Michael Fellinger @since 17-07-2009 @see Innate::Cache::API#cache_delete
# File lib/ramaze/cache/lru.rb, line 83 83: def cache_delete(*args) 84: super { |key| @store.delete(key) } 85: end
Retrieves a set of data from the cache.
@author Michael Fellinger @since 17-07-2009 @see Innate::Cache::API#cache_fetch
# File lib/ramaze/cache/lru.rb, line 72 72: def cache_fetch(*args) 73: super { |key| @store[key] } 74: end
Prepares the cache by creating a new instance of Ramaze::LRUHash using the options set in {Ramaze::Cache::LRU::OPTIONS}.
@author Michael Fellinger @since 17-07-2009
# File lib/ramaze/cache/lru.rb, line 40 40: def cache_setup(host, user, app, name) 41: @store = Ramaze::LRUHash.new(OPTIONS) 42: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.