The correct way is IMO: colleague.getMoney() which can easily be implemented in Java, PHP etc.
I'm getting a bit tired of this constant pecking at Java (nothing personal). There are a number of questionable designs yes, there is a lot of ugly code out there, yes, but almost every alternative might have been worse:
Teaching everyone C? Good luck.
Switch to C#? Until recently that would prevent you from using Linux on your servers unless you were ready to put in technical effort and bet on MS not suing you or the upstream effort.
Perl?
PHP?
Catch my drift folks? Java filled a niche. It was almost as easy as PHP once you got started (although onboarding still is messy I think) and provided superior tooling.
Not saying Java isn't a good choice for some things. Also, if functional programming languages were more popular, they would probably be subjected to the same ridicule for the same reasons.
While I agree with you, isn't that what the new streams in Java does? The map reduce complex?
you only need two spaces, actually
https://news.ycombinator.com/formatdoc