MemoizationDefaults { public static IntBinaryFunction<String> intBinaryOperatorHashCodeKeyFunction() { return (first, second) -> { final int firstHashCode = Integer.valueOf(first).hashCode(); final int secondHashCode = Integer.valueOf(second).hashCode(); return firstHashCode + " " + secondHashCode; }; } private  MemoizationDefaults(); static Supplier<String> defaultKeySupplier(); static BiFunction<T, U, String> hashCodeKeyFunction(); static ObjDoubleFunction<INPUT, String> objDoubleConsumerHashCodeKeyFunction(); static ObjIntFunction<INPUT, String> objIntConsumerHashCodeKeyFunction(); static ObjLongFunction<INPUT, String> objLongConsumerHashCodeKeyFunction(); static DoubleBinaryFunction<String> doubleBinaryOperatorHashCodeKeyFunction(); static IntBinaryFunction<String> intBinaryOperatorHashCodeKeyFunction(); static LongBinaryFunction<String> longBinaryOperatorHashCodeKeyFunction();  }
@Test public void shouldConcatIntBinaryOperatorHashCodesWithWhitespaceInbetween() { final IntBinaryFunction<String> keyFunction = MemoizationDefaults .intBinaryOperatorHashCodeKeyFunction(); final String calculatedKey = keyFunction.apply(123, 456); Assert.assertEquals("Calculated key does not match expectations", "123 456", calculatedKey); }