Campbell Ritchie wrote:Note the above classes are all mutable. It should be possible to envisage a scenario where the classes are immutable.
Thank you for your response and examples, they provide valuable insight and I wanted to point out two especially cool things:
Taking into account the lowest possible temperatureObjects.requireNonNull() - I didn't know about this method
Anyway, I just thought maybe what Bruce Eckel had it mind is the idea of "patching" the solution to allow new interactions, even if the end result is not the prettiest one, because when you just look at diagram it looks like someone hadn't idea about the future of the interface and text I quoted might support that point of view.
Thank you again for taking your time and providing the elaborate answer, especially because I asked this question on Discord and I bumped into dead silence there, and now, I feel like thermostat of my heart turned on the heater indeed
If you would care to take a look, I could send you my copy/fragment of the book, because I am not sure I have enough experience to value it in terms of the information content, so it would be helpful too.