commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1213729 - /commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java
Date Tue, 13 Dec 2011 15:04:58 GMT
Author: markt
Date: Tue Dec 13 15:04:57 2011
New Revision: 1213729

URL: http://svn.apache.org/viewvc?rev=1213729&view=rev
Log:
Fix POOL-198. Make protected things private.

Modified:
    commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java

Modified: commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java
URL: http://svn.apache.org/viewvc/commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java?rev=1213729&r1=1213728&r2=1213729&view=diff
==============================================================================
--- commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java
(original)
+++ commons/proper/pool/trunk/src/java/org/apache/commons/pool2/impl/LinkedBlockingDeque.java
Tue Dec 13 15:04:57 2011
@@ -88,7 +88,7 @@ public class LinkedBlockingDeque<E>
     private static final long serialVersionUID = -387911632671998426L;
 
     /** Doubly-linked list node class */
-    static final class Node<E> {
+    private static final class Node<E> {
         /**
          * The item, or null if this node has been removed.
          */
@@ -122,14 +122,14 @@ public class LinkedBlockingDeque<E>
      * Invariant: (first == null && last == null) ||
      *            (first.prev == null && first.item != null)
      */
-    transient Node<E> first;
+    private transient Node<E> first;
 
     /**
      * Pointer to last node.
      * Invariant: (first == null && last == null) ||
      *            (last.next == null && last.item != null)
      */
-    transient Node<E> last;
+    private transient Node<E> last;
 
     /** Number of items in the deque */
     private transient int count;
@@ -138,7 +138,7 @@ public class LinkedBlockingDeque<E>
     private final int capacity;
 
     /** Main lock guarding all access */
-    final ReentrantLock lock = new ReentrantLock();
+    private final ReentrantLock lock = new ReentrantLock();
 
     /** Condition for waiting takes */
     private final Condition notEmpty = lock.newCondition();
@@ -279,7 +279,7 @@ public class LinkedBlockingDeque<E>
     /**
      * Unlinks x.
      */
-    void unlink(Node<E> x) {
+    private void unlink(Node<E> x) {
         // assert lock.isHeldByCurrentThread();
         Node<E> p = x.prev;
         Node<E> n = x.next;



Mime
View raw message