Class Lazy<T> (1.10.0)

public class Lazy<T>

A thread-safe, lazily constructed instance of an object.

Inheritance

java.lang.Object > Lazy<T>

Type Parameter

NameDescription
T

Constructors

Lazy(Supplier<T> supplier)

public Lazy(Supplier<T> supplier)
Parameter
NameDescription
supplierSupplier<T>

Methods

get()

public synchronized T get()
Returns
TypeDescription
T