3 ms·
That only matters for interfaces which you expose to clients. The real problem with getters & setters & such is when they gum up the internal workings of a code
by bccdee 6y ago
That only matters for interfaces which you expose to clients. The real problem with getters & setters & such is when they gum up the internal workings of a codebase, abstracting over nothing and complicating things unnecessarily.
- millstone 6y agoI agree with that. If you create accessors as a matter of course, then you are mostly adding dead weight. But accessors can add a useful layer of abstraction at the interface layer, as you say.