Functional patterns for Java