Module: MemcachesPage::ClassMethods
- Defined in:
- lib/memcaches_page.rb
Instance Method Summary collapse
Instance Method Details
#memcache_page(content, path, options = {}) ⇒ Object
13 14 15 16 17 |
# File 'lib/memcaches_page.rb', line 13 def memcache_page(content, path, ={}) return unless perform_caching Rails.cache.write path.gsub('%', '%25'), content, .merge(raw: true) end |
#memcaches_page(*actions) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/memcaches_page.rb', line 4 def memcaches_page(*actions) return unless perform_caching = actions. after_filter({:only => actions}.merge()) do |c| c.memcache_page end end |