/** * Returns a composed {@link ThrowableBiCharToDoubleFunction} that first applies the {@code * before} functions to its input, and then applies this function to the result. This method is * just convenience, to provide the ability to execute an operation which accepts {@code char} * input, before this primitive function is executed. * * @param before1 The first function to apply before this function is applied * @param before2 The second operator to apply before this function is applied * @return A composed {@code ThrowableBiCharToDoubleFunction} that first applies the {@code * before} functions to its input, and then applies this function to the result. * @throws NullPointerException If given argument is {@code null} * @implSpec The input argument of this method is a able to handle primitive values. In this case * this is {@code char}. */ @Nonnull default ThrowableBiCharToDoubleFunction<X> composeFromChar( @Nonnull final ThrowableCharFunction<? extends T, ? extends X> before1, @Nonnull final ThrowableCharUnaryOperator<? extends X> before2) { Objects.requireNonNull(before1); Objects.requireNonNull(before2); return (value1, value2) -> applyAsDoubleThrows(before1.applyThrows(value1), before2.applyAsCharThrows(value2)); }
/** * Returns a composed {@link ThrowableTriCharToByteFunction} that first applies the {@code before} * functions to its input, and then applies this function to the result. This method is just * convenience, to provide the ability to execute an operation which accepts {@code char} input, * before this primitive function is executed. * * @param before1 The first function to apply before this function is applied * @param before2 The second predicate to apply before this function is applied * @param before3 The third predicate to apply before this function is applied * @return A composed {@code ThrowableTriCharToByteFunction} that first applies the {@code before} * functions to its input, and then applies this function to the result. * @throws NullPointerException If given argument is {@code null} * @implSpec The input argument of this method is a able to handle primitive values. In this case * this is {@code char}. */ @Nonnull default ThrowableTriCharToByteFunction<X> composeFromChar( @Nonnull final ThrowableCharFunction<? extends T, ? extends X> before1, @Nonnull final ThrowableCharPredicate<? extends X> before2, @Nonnull final ThrowableCharPredicate<? extends X> before3) { Objects.requireNonNull(before1); Objects.requireNonNull(before2); Objects.requireNonNull(before3); return (value1, value2, value3) -> applyAsByteThrows( before1.applyThrows(value1), before2.testThrows(value2), before3.testThrows(value3)); }
/** * Returns a composed {@link ThrowableTriCharToFloatFunction} that first applies the {@code * before} functions to its input, and then applies this function to the result. This method is * just convenience, to provide the ability to execute an operation which accepts {@code char} * input, before this primitive function is executed. * * @param before1 The first function to apply before this function is applied * @param before2 The second function to apply before this function is applied * @param before3 The third function to apply before this function is applied * @return A composed {@code ThrowableTriCharToFloatFunction} that first applies the {@code * before} functions to its input, and then applies this function to the result. * @throws NullPointerException If given argument is {@code null} * @implSpec The input argument of this method is a able to handle primitive values. In this case * this is {@code char}. */ @Nonnull default ThrowableTriCharToFloatFunction<X> composeFromChar( @Nonnull final ThrowableCharFunction<? extends T, ? extends X> before1, @Nonnull final ThrowableCharToLongFunction<? extends X> before2, @Nonnull final ThrowableCharToLongFunction<? extends X> before3) { Objects.requireNonNull(before1); Objects.requireNonNull(before2); Objects.requireNonNull(before3); return (value1, value2, value3) -> applyAsFloatThrows( before1.applyThrows(value1), before2.applyAsLongThrows(value2), before3.applyAsLongThrows(value3)); }