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

public final Class ObjectHelper

extends Object
Class Inheritance
Imports
io.reactivex.rxjava3.functions.BiPredicate, java.util.Objects

Utility methods containing the backport of Java 7's Objects utility class.

Named as such to avoid clash with java.util.Objects.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
pack-priv static final BiPredicate<Object, Object>

Constructor Summary

AccessConstructor and Description
private
ObjectHelper()

Utility class.

Method Summary

Modifier and TypeMethod and Description
public static <
the value type
T
>
BiPredicate<T, T>

Returns:

the bi-predicate instance
equalsPredicate
()

Returns a BiPredicate that compares its parameters via Objects.equals().

public static int

Returns:

value
verifyPositive
(int
the value to validate
value
,
String
the parameter name of the value
paramName
)

Validate that the given value is positive or report an IllegalArgumentException with the parameter name.

public static long

Returns:

value
verifyPositive
(long
the value to validate
value
,
String
the parameter name of the value
paramName
)

Validate that the given value is positive or report an IllegalArgumentException with the parameter name.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

EQUALSback to summary
pack-priv static final BiPredicate<Object, Object> EQUALS

Constructor Detail

ObjectHelperback to summary
private ObjectHelper()

Utility class.

Method Detail

equalsPredicateback to summary
public static <T> BiPredicate<T, T> equalsPredicate()

Returns a BiPredicate that compares its parameters via Objects.equals().

Parameters
<T>
the value type
Returns:BiPredicate<T, T>

the bi-predicate instance

Annotations
@SuppressWarnings:unchecked
verifyPositiveback to summary
public static int verifyPositive(int value, String paramName)

Validate that the given value is positive or report an IllegalArgumentException with the parameter name.

Parameters
value:int

the value to validate

paramName:String

the parameter name of the value

Returns:int

value

Exceptions
IllegalArgumentException:
if bufferSize <= 0
verifyPositiveback to summary
public static long verifyPositive(long value, String paramName)

Validate that the given value is positive or report an IllegalArgumentException with the parameter name.

Parameters
value:long

the value to validate

paramName:String

the parameter name of the value

Returns:long

value

Exceptions
IllegalArgumentException:
if bufferSize <= 0
io.reactivex.rxjava3.internal.functions back to summary

pack-priv final Class ObjectHelper.BiObjectPredicate

extends Object
implements BiPredicate<Object, Object>
Class Inheritance
  • java.lang.Object
  • io.reactivex.rxjava3.internal.functions.ObjectHelper.BiObjectPredicate
All Implemented Interfaces
io.reactivex.rxjava3.functions.BiPredicate

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public boolean
test(Object
the first value
o1
,
Object
the second value
o2
)

Implements io.reactivex.rxjava3.functions.BiPredicate.test.

Test the given input values and return a boolean.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

BiObjectPredicateback to summary
pack-priv BiObjectPredicate()

Method Detail

testback to summary
public boolean test(Object o1, Object o2)

Implements io.reactivex.rxjava3.functions.BiPredicate.test.

Doc from io.reactivex.rxjava3.functions.BiPredicate.test.

Test the given input values and return a boolean.

Parameters
o1:Object

the first value

o2:Object

the second value

Returns:boolean

the boolean result

Annotations
@Override