Class: Nitro::Caching::Proxy
- Inherits:
-
Object
- Object
- Nitro::Caching::Proxy
- Defined in:
- lib/nitro/caching/proxy.rb
Overview
A proxy to the caching system. This is typically used from the console. – gmosx: If anyone can suggest a better name, please speak up! ++
Class Method Summary collapse
- .cleanup_output ⇒ Object (also: cleanup)
Methods included from URLHelper
encode_absolute_url, encode_url
Methods included from Output
Class Method Details
.cleanup_output ⇒ Object Also known as: cleanup
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/nitro/caching/proxy.rb', line 20 def cleanup_output dirs = {} for ctrl, a in Nitro::Caching::Output.cached_actions file = encode_url(ctrl, a) file << 'index' if file == '/' unless dirs[file] puts "Expiring cache directory '#{file}'" expire_output(file) dirs[file] = true end file << '.html' puts "Expiring cache file '#{file}'" expire_output(file) end return true end |