public class PooledCollection<T>
extends Object
-
Constructor Summary
Constructors
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
PooledCollection
public PooledCollection(Supplier<T> instanceSupplier)
-
Method Details
-
-
release
public void release(T instance)
-
releaseAll
public void releaseAll()
-
-
processAll
public void processAll(@Nullable
@Nullable Consumer<T> createdConsumer,
@Nullable
@Nullable Consumer<T> oldConsumer,
@Nullable
@Nullable Consumer<T> releasedConsumer)
-
-
getCreated
public Set<T> getCreated()
-
getReleased
public Set<T> getReleased()