So, very often in your code you have statements/algorithms like this one:
if (!myCollection.contains(unit)) throw new IllegalArgumentException(s"$unit is not available")
The issue which I have with this approach that it clutters you source-code - this is especially true if you need extensive checks.
I was thinking if such repetitive algorithms, checks etc. are more elegant solvable in scala, e.g. by a DSL ?