IntUnaryOperator (@Nullable IntUnaryOperator convertor1, @Nullable IntUnaryOperator convertor2) { if (convertor1 == null && convertor2 == null) return null; if (convertor1 == null) return convertor2; if (convertor2 == null) return convertor1; return value -> { int value2 = convertor2.applyAsInt(value); return value2 >= 0 ? convertor1.applyAsInt(value2) : value2; }; }