instance method append_features

Ruby on Rails 3.2.22.5

Since v3.0.20 Last seen in v5.2.8.1

Available in: v3.0.20 v3.1.12 v3.2.22.5 v4.0.13 v4.1.16 v4.2.9 v5.2.8.1

Signature

append_features(base)

No documentation comment.

Parameters

base req
Source
# File activesupport/lib/active_support/concern.rb, line 107
    def append_features(base)
      if base.instance_variable_defined?("@_dependencies")
        base.instance_variable_get("@_dependencies") << self
        return false
      else
        return false if base < self
        @_dependencies.each { |dep| base.send(:include, dep) }
        super
        base.extend const_get("ClassMethods") if const_defined?("ClassMethods")
        if const_defined?("InstanceMethods")
          base.send :include, const_get("InstanceMethods")
          ActiveSupport::Deprecation.warn "The InstanceMethods module inside ActiveSupport::Concern will be " \
            "no longer included automatically. Please define instance methods directly in #{self} instead.", caller
        end
        base.class_eval(&@_included_block) if instance_variable_defined?("@_included_block")
      end
    end

Defined in activesupport/lib/active_support/concern.rb line 107 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveSupport::Concern

Type at least 2 characters to search.

↑↓ navigate · open · esc close