T - the type of the argument@FunctionalInterface public interface ObjToBool<T> extends ObjToBoolE<T,RuntimeException>, Predicate<T>
(T) -> boolean.| Modifier and Type | Method and Description |
|---|---|
static <T> NilToBool |
bind(ObjToBool<T> f,
T t)
Binds
(t) to f, returning a new function
of type () -> boolean. |
default NilToBool |
bind(T t)
Binds
(t) to this, returning a new function
of type () -> boolean. |
default boolean |
test(T t)
Allows
this to act as a Predicate<T>. |
static <T,E extends Exception> |
unchecked(Function<? super E,RuntimeException> toRuntime,
ObjToBoolE<T,E> f)
Returns a wrapped version of
f that uses toRuntime to convert any checked
Exception to a RuntimeException. |
static <T,E extends Exception> |
unchecked(ObjToBoolE<T,E> f)
Returns a wrapped version of
f that wraps any checked Exception with a
RuntimeException. |
static <T,E extends IOException> |
uncheckedIO(ObjToBoolE<T,E> f)
|
bind, callstatic <T,E extends Exception> ObjToBool<T> unchecked(Function<? super E,RuntimeException> toRuntime, ObjToBoolE<T,E> f)
f that uses toRuntime to convert any checked
Exception to a RuntimeException.T - the type of argument 1E - the Exception type that the operation may throwtoRuntime - if a checked exception is thrown from
ObjToBoolE.call(T), then this function
is called in in order to convert it to a RuntimeExceptionf - the operation to wrapf that does not throw checked exceptionsstatic <T,E extends Exception> ObjToBool<T> unchecked(ObjToBoolE<T,E> f)
f that wraps any checked Exception with a
RuntimeException.T - the type of argument 1E - the Exception type that the operation may throwf - the operation to wrapf that does not throw checked exceptionsstatic <T,E extends IOException> ObjToBool<T> uncheckedIO(ObjToBoolE<T,E> f)
T - the type of argument 1E - the Exception type that the operation may throwf - the operation to wrapf that throws UncheckedIOException instead of
IOExceptionstatic <T> NilToBool bind(ObjToBool<T> f, T t)
(t) to f, returning a new function
of type () -> boolean.T - the type of the argumentf - the unbound functiont - the argument() -> boolean that calls
f.call(t) and returns the result.default NilToBool bind(T t)
(t) to this, returning a new function
of type () -> boolean.bind in interface ObjToBoolE<T,RuntimeException>t - the argument() -> boolean that calls
this.call(t) and returns the result.Copyright © 2015. All rights reserved.