Module: CacheFinder::Helper

Included in:
CacheCleaner::Cleaner, Container
Defined in:
lib/cache_finder/finder/container.rb

Instance Method Summary collapse

Instance Method Details

#cache_container_key?(data) ⇒ Boolean

Helper method. You could find out the way of generating keys by calling this method on a class.

Example:

Chain.cache_container_key?(:name) # => ["Chain", :name]

Returns:

  • (Boolean)


13
14
15
16
17
# File 'lib/cache_finder/finder/container.rb', line 13

def cache_container_key?(data)
  key = *data
  key.unshift(self.name)
  key
end