Package rx.internal.util
Class UtilityFunctions
- java.lang.Object
-
- rx.internal.util.UtilityFunctions
-
public final class UtilityFunctions extends java.lang.Object
Utility functions for internal use that we don't want part of the public API.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
UtilityFunctions.AlwaysFalse
(package private) static class
UtilityFunctions.AlwaysTrue
-
Constructor Summary
Constructors Modifier Constructor Description private
UtilityFunctions()
Utility class.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> Func1<? super T,java.lang.Boolean>
alwaysFalse()
Returns a function that always returnsfalse
.static <T> Func1<? super T,java.lang.Boolean>
alwaysTrue()
Returns a function that always returnstrue
.static <T> Func1<T,T>
identity()
Returns a function that always returns the Object it is passed.
-
-
-
Method Detail
-
alwaysTrue
public static <T> Func1<? super T,java.lang.Boolean> alwaysTrue()
Returns a function that always returnstrue
.- Type Parameters:
T
- the value type- Returns:
- a
Func1
that accepts an Object and returns the Booleantrue
-
alwaysFalse
public static <T> Func1<? super T,java.lang.Boolean> alwaysFalse()
Returns a function that always returnsfalse
.- Type Parameters:
T
- the value type- Returns:
- a
Func1
that accepts an Object and returns the Booleanfalse
-
-