Scala flavored useful API in Java