Class: ActionController::Caching::Sweeper
- Inherits:
-
ActiveRecord::Observer
- Object
- ActiveRecord::Observer
- ActionController::Caching::Sweeper
- Defined in:
- lib/action_controller/caching.rb
Overview
:nodoc:
Instance Attribute Summary collapse
-
#controller ⇒ Object
Returns the value of attribute controller.
Instance Method Summary collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *arguments) ⇒ Object (private)
662 663 664 665 |
# File 'lib/action_controller/caching.rb', line 662 def method_missing(method, *arguments) return if @controller.nil? @controller.send!(method, *arguments) end |
Instance Attribute Details
#controller ⇒ Object
Returns the value of attribute controller.
629 630 631 |
# File 'lib/action_controller/caching.rb', line 629 def controller @controller end |
Instance Method Details
#after(controller) ⇒ Object
636 637 638 639 640 |
# File 'lib/action_controller/caching.rb', line 636 def after(controller) callback(:after) # Clean up, so that the controller can be collected after this request self.controller = nil end |
#before(controller) ⇒ Object
631 632 633 634 |
# File 'lib/action_controller/caching.rb', line 631 def before(controller) self.controller = controller callback(:before) end |