Uses of Interface
org.apache.commons.lang3.function.FailableConsumer
-
Packages that use FailableConsumer Package Description org.apache.commons.lang3 Provides highly reusable utility methods, chiefly concerned with adding value to thejava.langclasses.org.apache.commons.lang3.concurrent Provides support classes for multi-threaded programming.org.apache.commons.lang3.concurrent.locks Provides support classes for multi-threaded programming.org.apache.commons.lang3.event Provides some useful event-based utilities.org.apache.commons.lang3.function Provides functional interfaces to complement those injava.lang.functionand utilities for working with Java 8 lambdas.org.apache.commons.lang3.stream Provides utility classes to complement those injava.util.stream.org.apache.commons.lang3.time Provides classes and methods to work with dates and durations. -
-
Uses of FailableConsumer in org.apache.commons.lang3
Methods in org.apache.commons.lang3 with parameters of type FailableConsumer Modifier and Type Method Description static voidAutoCloseables. close(java.lang.AutoCloseable closeable, FailableConsumer<java.lang.Exception,java.lang.Exception> consumer)Closes the givenAutoCloseableas a null-safe operation. -
Uses of FailableConsumer in org.apache.commons.lang3.concurrent
Methods in org.apache.commons.lang3.concurrent that return FailableConsumer Modifier and Type Method Description FailableConsumer<T,? extends java.lang.Exception>AbstractConcurrentInitializer.AbstractBuilder. getCloser()Gets the closer consumer called byAbstractConcurrentInitializer.close().Methods in org.apache.commons.lang3.concurrent with parameters of type FailableConsumer Modifier and Type Method Description BAbstractConcurrentInitializer.AbstractBuilder. setCloser(FailableConsumer<T,? extends java.lang.Exception> closer)Sets the closer consumer called byAbstractConcurrentInitializer.close(). -
Uses of FailableConsumer in org.apache.commons.lang3.concurrent.locks
Methods in org.apache.commons.lang3.concurrent.locks with parameters of type FailableConsumer Modifier and Type Method Description voidLockingVisitors.LockVisitor. acceptReadLocked(FailableConsumer<O,?> consumer)Invokes the consumer while holding the lock supplied for read operations.voidLockingVisitors.LockVisitor. acceptWriteLocked(FailableConsumer<O,?> consumer)Invokes the consumer while holding the lock supplied for write operations.protected voidLockingVisitors.LockVisitor. lockAcceptUnlock(java.util.function.Supplier<java.util.concurrent.locks.Lock> lockSupplier, FailableConsumer<O,?> consumer) -
Uses of FailableConsumer in org.apache.commons.lang3.event
Constructors in org.apache.commons.lang3.event with parameters of type FailableConsumer Constructor Description ProxyInvocationHandler(FailableConsumer<java.lang.Throwable,java.lang.IllegalAccessException> handler)Constructs a new instance. -
Uses of FailableConsumer in org.apache.commons.lang3.function
Fields in org.apache.commons.lang3.function declared as FailableConsumer Modifier and Type Field Description static FailableConsumerFailableConsumer. NOPNOP singletonMethods in org.apache.commons.lang3.function that return FailableConsumer Modifier and Type Method Description default FailableConsumer<T,E>FailableConsumer. andThen(FailableConsumer<? super T,E> after)Returns a composedConsumerlikeConsumer.andThen(Consumer).static <T,E extends java.lang.Throwable>
FailableConsumer<T,E>FailableConsumer. nop()Gets the NOP singleton.Methods in org.apache.commons.lang3.function with parameters of type FailableConsumer Modifier and Type Method Description static <T,E extends java.lang.Throwable>
voidFailable. accept(FailableConsumer<T,E> consumer, T object)Consumes a consumer and rethrows any exception as aRuntimeException.static <T,E extends java.lang.Throwable>
voidFailableConsumer. accept(FailableConsumer<T,E> consumer, T object)Applies the givenFailableConsumeraction to the object if the consumer is notnull.default FailableConsumer<T,E>FailableConsumer. andThen(FailableConsumer<? super T,E> after)Returns a composedConsumerlikeConsumer.andThen(Consumer).static <T> java.util.function.Consumer<T>Failable. asConsumer(FailableConsumer<T,?> consumer)Converts the givenFailableConsumerinto a standardConsumer.static voidFailable. tryWithResources(FailableRunnable<? extends java.lang.Throwable> action, FailableConsumer<java.lang.Throwable,? extends java.lang.Throwable> errorHandler, FailableRunnable<? extends java.lang.Throwable>... resources)A simple try-with-resources implementation, that can be used, if your objects do not implement theAutoCloseableinterface. -
Uses of FailableConsumer in org.apache.commons.lang3.stream
Methods in org.apache.commons.lang3.stream with parameters of type FailableConsumer Modifier and Type Method Description voidStreams.FailableStream. forEach(FailableConsumer<T,?> action)Performs an action for each element of this stream. -
Uses of FailableConsumer in org.apache.commons.lang3.time
Methods in org.apache.commons.lang3.time with parameters of type FailableConsumer Modifier and Type Method Description static <E extends java.lang.Throwable>
java.time.DurationDurationUtils. of(FailableConsumer<java.time.Instant,E> consumer)Runs the lambda and returns the duration of its execution.
-