| Package | Description |
|---|---|
| java.lang |
Provides classes that are fundamental to the design of the Java programming language.
|
| java.util |
Contains the collections framework, legacy collection classes, event model, date and time facilities, internationalization, and miscellaneous utility classes (a string tokenizer, a random-number generator, and a bit array).
|
| java.util.concurrent |
Utility classes commonly useful in concurrent programming.
|
| java.util.logging |
Provides the classes and interfaces of the Java
TM 2 platform's core logging facilities.
|
| java.util.stream |
Classes to support functional-style operations on streams of elements, such as map-reduce transformations on collections.
|
| Modifier and Type | Method and Description |
|---|---|
static <S> ThreadLocal |
ThreadLocal.withInitial(Supplier
Creates a thread local variable.
|
| Modifier and Type | Method and Description |
|---|---|
T |
Optional.orElseGet(Supplier
Return the value if present, otherwise invoke
other and return the result of that invocation.
|
<X extends Throwable |
Optional.orElseThrow(Supplier
Return the contained value, if present, otherwise throw an exception to be created by the provided supplier.
|
<X extends Throwable |
OptionalDouble.orElseThrow(Supplier
Return the contained value, if present, otherwise throw an exception to be created by the provided supplier.
|
<X extends Throwable |
OptionalInt.orElseThrow(Supplier
Return the contained value, if present, otherwise throw an exception to be created by the provided supplier.
|
<X extends Throwable |
OptionalLong.orElseThrow(Supplier
Return the contained value, if present, otherwise throw an exception to be created by the provided supplier.
|
static <T> T |
Objects.requireNonNull(T obj, Supplier
Checks that the specified object reference is not
null and throws a customized
NullPointerException if it is.
|
| Modifier and Type | Method and Description |
|---|---|
static <U> CompletableFuture |
CompletableFuture.supplyAsync(Supplier
Returns a new CompletableFuture that is asynchronously completed by a task running in the
ForkJoinPool with the value obtained by calling the given Supplier.
|
static <U> CompletableFuture |
CompletableFuture.supplyAsync(Supplier
Returns a new CompletableFuture that is asynchronously completed by a task running in the given executor with the value obtained by calling the given Supplier.
|
| Modifier and Type | Method and Description |
|---|---|
void |
Logger.config(Supplier
Log a CONFIG message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.fine(Supplier
Log a FINE message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.finer(Supplier
Log a FINER message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.finest(Supplier
Log a FINEST message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.info(Supplier
Log a INFO message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.log(Level
Log a message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.log(Level
Log a lazily constructed message, with associated Throwable information.
|
void |
Logger.logp(Level
Log a lazily constructed message, specifying source class and method, with no arguments.
|
void |
Logger.logp(Level
Log a lazily constructed message, specifying source class and method, with associated Throwable information.
|
void |
Logger.severe(Supplier
Log a SEVERE message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
void |
Logger.warning(Supplier
Log a WARNING message, which is only to be constructed if the logging level is such that the message will actually be logged.
|
| Modifier and Type | Method and Description |
|---|---|
Supplier |
Collector.supplier()
A function that creates and returns a new mutable result container.
|
| Modifier and Type | Method and Description |
|---|---|
<R> R |
Stream.collect(Supplier
Performs a
mutable reduction operation on the elements of this stream.
|
<R> R |
DoubleStream.collect(Supplier
Performs a
mutable reduction operation on the elements of this stream.
|
<R> R |
IntStream.collect(Supplier
Performs a
mutable reduction operation on the elements of this stream.
|
<R> R |
LongStream.collect(Supplier
Performs a
mutable reduction operation on the elements of this stream.
|
static DoubleStream |
StreamSupport.doubleStream(Supplier
Creates a new sequential or parallel
DoubleStream from a
Supplier of
Spliterator.OfDouble.
|
static <T> Stream |
Stream.generate(Supplier
Returns an infinite sequential unordered stream where each element is generated by the provided
Supplier.
|
static <T |
Collectors.groupingBy(Function
Returns a
Collector implementing a cascaded "group by" operation on input elements of type
T, grouping elements according to a classification function, and then performing a reduction operation on the values associated with a given key using the specified downstream
Collector.
|
static <T |
Collectors.groupingByConcurrent(Function
Returns a concurrent
Collector implementing a cascaded "group by" operation on input elements of type
T, grouping elements according to a classification function, and then performing a reduction operation on the values associated with a given key using the specified downstream
Collector.
|
static IntStream |
StreamSupport.intStream(Supplier
Creates a new sequential or parallel
IntStream from a
Supplier of
Spliterator.OfInt.
|
static LongStream |
StreamSupport.longStream(Supplier
Creates a new sequential or parallel
LongStream from a
Supplier of
Spliterator.OfLong.
|
static <T |
Collector.of(Supplier
Returns a new
Collector described by the given
supplier,
accumulator,
combiner, and
finisher functions.
|
static <T |
Collector.of(Supplier
Returns a new
Collector described by the given
supplier,
accumulator, and
combiner functions.
|
static <T> Stream |
StreamSupport.stream(Supplier
Creates a new sequential or parallel
Stream from a
Supplier of
Spliterator.
|
static <T |
Collectors.toCollection(Supplier
Returns a
Collector that accumulates the input elements into a new
Collection, in encounter order.
|
static <T |
Collectors.toConcurrentMap(Function
Returns a concurrent
Collector that accumulates elements into a
ConcurrentMap whose keys and values are the result of applying the provided mapping functions to the input elements.
|
static <T |
Collectors.toMap(Function
Returns a
Collector that accumulates elements into a
Map whose keys and values are the result of applying the provided mapping functions to the input elements.
|