instance method get_from_memory_cache

Ruby on Rails 2.2.3

Last seen in v2.2.3 Private — implementation detail, not part of the public API

Signature

get_from_memory_cache(filename, cache)

Returns a cache entry from a memory cache belonging to a certain filename. If no entry could be found for any reason, nil will be returned.

filename

Name of the file the cache entry belongs to.

cache

Memory cache to get entry from.

Parameters

filename req
cache req
Source
# File activesupport/lib/active_support/vendor/xml-simple-1.0.11/xmlsimple.rb, line 114
    def get_from_memory_cache(filename, cache)
      return nil unless cache[filename]
      return nil unless cache[filename][0] > File::mtime(filename).to_i
      return cache[filename][1]
    end

Defined in activesupport/lib/active_support/vendor/xml-simple-1.0.11/xmlsimple.rb line 114 · View on GitHub · Improve this page · Find usages on GitHub

Defined in XmlSimple::Cache

Type at least 2 characters to search.

Use the arrow keys to navigate results, Enter to open one, Escape to close.

Keyboard shortcuts

/
Focus search
⌘K / Ctrl-K
Command palette
?
This help
Esc
Close