instance method caches_action

Ruby on Rails 2.2.3

Since v2.2.3 Last seen in v3.2.22.5

Available in: v2.2.3 v2.3.18 v3.0.20 v3.1.12 v3.2.22.5

Signature

caches_action(*actions)

Declares that actions should be cached. See ActionController::Caching::Actions for details.

Parameters

actions rest
Source
# File actionpack/lib/action_controller/caching/actions.rb, line 58
        def caches_action(*actions)
          return unless cache_configured?
          options = actions.extract_options!
          filter_options = { :only => actions, :if => options.delete(:if), :unless => options.delete(:unless) }

          cache_filter = ActionCacheFilter.new(:layout => options.delete(:layout), :cache_path => options.delete(:cache_path), :store_options => options)
          around_filter(cache_filter, filter_options)
        end

Defined in actionpack/lib/action_controller/caching/actions.rb line 58 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionController::Caching::Actions::ClassMethods

Type at least 2 characters to search.

↑↓ navigate · open · esc close