Module: Reloadable::Subclasses
- Defined in:
- lib/active_support/reloadable.rb
Overview
Captures the common pattern where a base class should not be reloaded, but its subclasses should be.
Deprecated as of Rails 1.2. All autoloaded objects are now unloaded.
Class Method Summary collapse
-
.included(base) ⇒ Object
:nodoc:.
Class Method Details
.included(base) ⇒ Object
:nodoc:
40 41 42 43 44 45 46 47 |
# File 'lib/active_support/reloadable.rb', line 40 def self.included(base) #nodoc: base.send :include, Reloadable ActiveSupport::Deprecation.warn "Reloadable::Subclasses has been deprecated and has no effect.", caller (class << base; self; end).send(:define_method, :reloadable?) do ActiveSupport::Deprecation.warn "Reloadable has been deprecated and reloadable? has no effect", caller base != self end end |