This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch POOL_2_X in repository https://gitbox.apache.org/repos/asf/commons-pool.git
commit 0af8f39f585a599298d17ffa1920560df854d5ff Author: Gary Gregory <[email protected]> AuthorDate: Sat Nov 29 15:24:23 2025 +0000 Reduce visibility of some private class' methods Javadoc --- .../commons/pool2/impl/GenericKeyedObjectPool.java | 16 ++++++++-------- .../commons/pool2/impl/InterruptibleReentrantLock.java | 6 +++--- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java b/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java index 5abe74d0..494ca291 100644 --- a/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java +++ b/src/main/java/org/apache/commons/pool2/impl/GenericKeyedObjectPool.java @@ -135,9 +135,9 @@ public class GenericKeyedObjectPool<K, T> extends BaseGenericObjectPool<T> /** * Gets all the objects for the current key. * - * @return All the objects + * @return All the objects. */ - public Map<IdentityWrapper<S>, PooledObject<S>> getAllObjects() { + Map<IdentityWrapper<S>, PooledObject<S>> getAllObjects() { return allObjects; } @@ -145,27 +145,27 @@ public class GenericKeyedObjectPool<K, T> extends BaseGenericObjectPool<T> * Gets the number of instances created - number destroyed. * Should always be less than or equal to maxTotalPerKey. * - * @return The net instance addition count for this deque + * @return The net instance addition count for this deque. */ - public AtomicInteger getCreateCount() { + AtomicInteger getCreateCount() { return createCount; } /** * Gets the idle objects for the current key. * - * @return The idle objects + * @return The idle objects. */ - public LinkedBlockingDeque<PooledObject<S>> getIdleObjects() { + LinkedBlockingDeque<PooledObject<S>> getIdleObjects() { return idleObjects; } /** * Gets the number of threads with an interest registered in this key. * - * @return The number of threads with a registered interest in this key + * @return The number of threads with a registered interest in this key. */ - public AtomicLong getNumInterested() { + AtomicLong getNumInterested() { return numInterested; } diff --git a/src/main/java/org/apache/commons/pool2/impl/InterruptibleReentrantLock.java b/src/main/java/org/apache/commons/pool2/impl/InterruptibleReentrantLock.java index 525877b5..52824da9 100644 --- a/src/main/java/org/apache/commons/pool2/impl/InterruptibleReentrantLock.java +++ b/src/main/java/org/apache/commons/pool2/impl/InterruptibleReentrantLock.java @@ -37,18 +37,18 @@ final class InterruptibleReentrantLock extends ReentrantLock { * Constructs a new InterruptibleReentrantLock with the given fairness policy. * * @param fairness true means threads should acquire contended locks as if - * waiting in a FIFO queue + * waiting in a FIFO queue. */ InterruptibleReentrantLock(final boolean fairness) { super(fairness); } /** - * Interrupts the threads that are waiting on a specific condition + * Interrupts the threads that are waiting on a specific condition. * * @param condition the condition on which the threads are waiting. */ - public void interruptWaiters(final Condition condition) { + void interruptWaiters(final Condition condition) { getWaitingThreads(condition).forEach(Thread::interrupt); } }
