- java.lang.Object
-
- org.cryptomator.cryptolib.common.ObjectPool.Lease<T>
-
- Type Parameters:
T- Type of the leased instance
- All Implemented Interfaces:
AutoCloseable,Supplier<T>
- Enclosing class:
- ObjectPool<T>
public static class ObjectPool.Lease<T> extends Object implements AutoCloseable, Supplier<T>
A holder for resource leased from anObjectPool. This is basically anautocloseableSupplierthat is intended to be used via try-with-resource blocks.