Comparison
Long parameter listvsTelescoping constructor
Long parameter list
the method takes nine arguments, four of them are the same type, and you got two of them the wrong way round.
A signature with enough parameters that call sites become positional puzzles and mistakes stop being caught by types. It is usually a symptom rather than the problem: several parameters that always travel together are a missing object, and a flag among them is a missing second method. A builder or a parameter object addresses the readability; a smaller responsibility addresses the cause.
Full entry →Telescoping constructor
there are six constructors, each calling the next with one more default, and you count commas to find your argument.
The pattern of overloading a constructor repeatedly to fake optional parameters, each version delegating to a longer one. It scales badly the moment two optional parameters have the same type, because the call site becomes positional guesswork and the compiler cannot help. It is the specific problem the builder pattern was popularised to fix, and in languages with named or default arguments it simply does not arise.
Full entry →