Module: RuboCop::Cop::OnMethodDef
- Included in:
- Lint::DefEndAlignment, Lint::UselessSetterCall, MethodComplexity, Metrics::MethodLength, Rails::Delegate, Style::AccessorMethodName, Style::DefWithParentheses, Style::EmptyLinesAroundMethodBody, Style::IndentationWidth, Style::MethodDefParentheses, Style::NonNilCheck, Style::PredicateName, Style::RedundantBegin, Style::RedundantReturn, Style::RescueModifier, Style::SingleLineMethods, Style::SpaceAfterMethodName, Style::TrivialAccessors
- Defined in:
- lib/rubocop/cop/mixin/on_method_def.rb
Overview
Common functionality for checking instance methods and singeton methods.
Instance Method Summary collapse
Instance Method Details
#on_def(node) ⇒ Object
7 8 9 10 |
# File 'lib/rubocop/cop/mixin/on_method_def.rb', line 7 def on_def(node) method_name, args, body = *node on_method_def(node, method_name, args, body) end |
#on_defs(node) ⇒ Object
12 13 14 15 |
# File 'lib/rubocop/cop/mixin/on_method_def.rb', line 12 def on_defs(node) _scope, method_name, args, body = *node on_method_def(node, method_name, args, body) end |