CleanCode
CleanCode copied to clipboard
Ignore "Too many arguments" on methods that implement interfaces
3rd party or builtin interfaces may have methods requiring several arguments (e.g. Xamarin.Forms.IValueConverter
, which defines Convert
and ConvertBack
with four arguments each). In these cases, CleanCode should not warn that the methods that implement the interfaces require too many arguments.
In general, I suggest that interface-implementing methods should be skipped entirely by the "too many arguments" check, and instead CleanCode should warn about this on the actual interface definitions.
In general it would be nice to have an option to include "just my code" or to exclude the BCL / third party libraries. Fox example when implementing IList<T>.Add(T item)
it raises a MethodNameNotMeaningful
warning. Obviously there is nothing we can do about it except ignoring it.