ToBooleanNullableImpl implements NullableExpression<T, ToBoolean<T>>, ToBooleanNullable<T> { @Override public Boolean apply(T t) { return isNull.test(t) ? null : original.applyAsBoolean(t); } ToBooleanNullableImpl(ToBoolean<T> original, Predicate<T> isNull); @Override ToBoolean<T> inner(); @Override Predicate<T> isNullPredicate(); @Override Boolean apply(T t); @Override boolean applyAsBoolean(T t); @Override ToBoolean<T> orThrow(); @Override ToBoolean<T> orElseGet(ToBoolean<T> getter); @Override ToBoolean<T> orElse(Boolean value); @Override ToDoubleNullable<T> mapToDoubleIfPresent(BooleanToDoubleFunction mapper); @Override ToBooleanNullable<T> mapIfPresent(BooleanUnaryOperator mapper); @Override long hash(T object); @Override int compare(T first, T second); @Override boolean isNull(T object); @Override boolean isNotNull(T object); @Override boolean equals(Object o); @Override int hashCode();  }
@Test void apply() { assertNull(instance.apply(null)); assertTrue(instance.apply("test")); assertFalse(instance.apply("ab")); }