class Locomotive::Steam::Adapters::Filesystem::SimpleCacheStore
Public Instance Methods
_store()
click to toggle source
:nocov:
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 34 def _store @@store end
clear()
click to toggle source
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 25 def clear @@store.clear end
delete(name)
click to toggle source
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 29 def delete(name) @@store.delete(name) end
fetch(name, options = nil) { || ... }
click to toggle source
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 9 def fetch(name, options = nil, &block) if block_given? read(name) || write(name, yield) else read(name) end end
read(name, options = nil)
click to toggle source
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 17 def read(name, options = nil) @@store[name] end
write(name, value, options = nil)
click to toggle source
# File lib/locomotive/steam/adapters/filesystem/simple_cache_store.rb, line 21 def write(name, value, options = nil) @@store[name] = value end