4 ms·
Thanks for asking! My answer, of course, depends on the particular scenario. I've had success with simple static methods, especially early in a project. I'd als
by jlewallen 11y ago
Thanks for asking! My answer, of course, depends on the particular scenario. I've had success with simple static methods, especially early in a project. I'd also consider some kind of composition (has-a vs is-a). The latter can be especially nice as static methods gain complexity in the form of more parameters/variations. This also shines if there's meaningful alternative implementations that can be swapped or if you're writing business logic and some legitimate business concepts start to congeal out of the code being re-used.