Top Description Inners Fields Constructors Methods
io.reactivex.rxjava3.internal.functions

public final Class Functions

extends Object
Class Inheritance
Imports
java.util.*, java.util.concurrent.*, org.reactivestreams.Subscription, io.reactivex.rxjava3.annotations.NonNull, io.reactivex.rxjava3.core.*, io.reactivex.rxjava3.exceptions.OnErrorNotImplementedException, io.reactivex.rxjava3.functions.*, io.reactivex.rxjava3.plugins.RxJavaPlugins, io.reactivex.rxjava3.schedulers.Timed

Utility methods to convert the BiFunction, Function3..Function9 instances to Function of Object array.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
pack-priv static class
pack-priv static class
Functions.Array3Func<T1, T2, T3, R>

pack-priv static class
Functions.Array4Func<T1, T2, T3, T4, R>

pack-priv static class
Functions.Array5Func<T1, T2, T3, T4, T5, R>

pack-priv static class
Functions.Array6Func<T1, T2, T3, T4, T5, T6, R>

pack-priv static class
Functions.Array7Func<T1, T2, T3, T4, T5, T6, T7, R>

pack-priv static class
Functions.Array8Func<T1, T2, T3, T4, T5, T6, T7, T8, R>

pack-priv static class
Functions.Array9Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, R>

pack-priv static class
pack-priv static class
public static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static enum
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static enum
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class

Field Summary

Modifier and TypeField and Description
pack-priv static final Predicate<Object>
pack-priv static final Predicate<Object>
public static final Action
pack-priv static final Consumer<Object>
public static final LongConsumer
public static final Runnable
public static final Consumer<Throwable>
pack-priv static final Function<Object, Object>
IDENTITY

A singleton identity function.

pack-priv static final Supplier<Object>
public static final Consumer<Throwable>
ON_ERROR_MISSING

Wraps the consumed Throwable into an OnErrorNotImplementedException and signals it to the plugin error handler.

public static final Consumer<Subscription>

Constructor Summary

AccessConstructor and Description
private
Functions()

Utility class.

Method Summary

Modifier and TypeMethod and Description
public static <T> Consumer<T>
public static <T> @NonNull Predicate<T>
public static <T> @NonNull Predicate<T>
public static <T> Consumer<T>
boundedConsumer(int bufferSize)

public static <
the input value type
T
,
the output and target type
U
>
@NonNull Function<T, U>

Returns:

the new Function instance
castFunction
(@NonNull Class<U>
the target class
target
)

Returns a function that cast the incoming values via a Class object.

public static <T> Supplier<List<T>>
createArrayList(int capacity)

public static <T> Supplier<Set<T>>
public static <
the consumed value type, the value is ignored
T
>
Consumer<T>

Returns:

an empty consumer that does nothing.
emptyConsumer
()

Returns an empty consumer that does nothing.

public static <T> Predicate<T>
equalsWith(T value)

public static @NonNull Action

Returns:

the new Action instance
futureAction
(@NonNull Future<?>
the future to call get() on, not null
future
)

Wraps the blocking get call of the Future into an Action.

public static <
the input and output value type
T
>
@NonNull Function<T, T>

Returns:

the identity function
identity
()

Returns an identity function that simply returns its argument.

public static <T, U> Predicate<T>
isInstanceOf(Class<U> clazz)

public static <
the value type
T
>
@NonNull Callable<T>

Returns:

the new Callable instance
justCallable
(T
the value to return
value
)

Returns a Callable that returns the given value.

public static <
the function's input type
T
,
the value and return type of the function
U
>
@NonNull Function<T, U>

Returns:

the new Function instance
justFunction
(U
the value to return
value
)

Returns a Function that ignores its parameter and returns the given value.

public static <
the value type
T
>
@NonNull Supplier<T>

Returns:

the new Callable instance
justSupplier
(T
the value to return
value
)

Returns a Supplier that returns the given value.

public static <T> Function<List<T>, List<T>>
listSorter(final Comparator<? super T> comparator)

public static <T> Comparator<T>
public static <T> Action
notificationOnComplete(Consumer<? super Notification<T>> onNotification)

public static <T> Consumer<Throwable>
notificationOnError(Consumer<? super Notification<T>> onNotification)

public static <T> Consumer<T>
notificationOnNext(Consumer<? super Notification<T>> onNotification)

public static <T> @NonNull Supplier<T>
public static <T> Predicate<T>
public static <T> Function<T, Timed<T>>
timestampWith(TimeUnit unit, Scheduler scheduler)

public static <T1, T2, R> @NonNull Function<Object[], R>
toFunction(@NonNull BiFunction<? super T1, ? super T2, ? extends R> f)

public static <T1, T2, T3, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function3<T1, T2, T3, R> f)

public static <T1, T2, T3, T4, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function4<T1, T2, T3, T4, R> f)

public static <T1, T2, T3, T4, T5, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function5<T1, T2, T3, T4, T5, R> f)

public static <T1, T2, T3, T4, T5, T6, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function6<T1, T2, T3, T4, T5, T6, R> f)

public static <T1, T2, T3, T4, T5, T6, T7, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function7<T1, T2, T3, T4, T5, T6, T7, R> f)

public static <T1, T2, T3, T4, T5, T6, T7, T8, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function8<T1, T2, T3, T4, T5, T6, T7, T8, R> f)

public static <T1, T2, T3, T4, T5, T6, T7, T8, T9, R> @NonNull Function<Object[], R>
toFunction(@NonNull Function9<T1, T2, T3, T4, T5, T6, T7, T8, T9, R> f)

public static <T, K> BiConsumer<Map<K, T>, T>
toMapKeySelector(final Function<? super T, ? extends K> keySelector)

public static <T, K, V> BiConsumer<Map<K, V>, T>
toMapKeyValueSelector(final Function<? super T, ? extends K> keySelector, final Function<? super T, ? extends V> valueSelector)

public static <T, K, V> BiConsumer<Map<K, Collection<V>>, T>
toMultimapKeyValueSelector(final Function<? super T, ? extends K> keySelector, final Function<? super T, ? extends V> valueSelector, final Function<? super K, ? extends Collection<? super V>> collectionFactory)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait