Package software.amazon.awssdk.utils
Class Lazy<T>
java.lang.Object
software.amazon.awssdk.utils.Lazy<T>
- All Implemented Interfaces:
AutoCloseable
,SdkAutoCloseable
A class that lazily constructs a value the first time
getValue()
is invoked.
This should be close()
d if the initializer returns value that needs to be AutoCloseable.close()
d.-
Constructor Summary
-
Method Summary
-
Constructor Details
-
Lazy
-
-
Method Details
-
withValue
-
hasValue
public boolean hasValue() -
getValue
-
toString
-
close
public void close()Description copied from interface:SdkAutoCloseable
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceSdkAutoCloseable
-