Class: RuboCop::Cop::Kaizo::KeywordArguments
- Inherits:
-
Base
- Object
- Base
- RuboCop::Cop::Kaizo::KeywordArguments
- Includes:
- ArgumentCounting
- Defined in:
- lib/rubocop/cop/kaizo/keyword_arguments.rb
Overview
Checks that a method does not declare too many keyword arguments.
Keyword arguments are self-documenting, but a long list of them is still
a sign that the related values want to be modeled as an object. Required
(kwarg) and optional (kwoptarg) parameters are counted; **rest is
not.
Constant Summary collapse
- KIND =
"keyword arguments".freeze
Constants included from ArgumentCounting
ArgumentCounting::DEFINE_METHODS, ArgumentCounting::KEYWORD_TYPES, ArgumentCounting::MSG, ArgumentCounting::POSITIONAL_TYPES, ArgumentCounting::STRUCT_OR_DATA