ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/jsr166x/LinkedBlockingDeque.java
(Generate patch)

Comparing jsr166/src/jsr166x/LinkedBlockingDeque.java (file contents):
Revision 1.3 by jsr166, Mon Nov 16 04:16:42 2009 UTC vs.
Revision 1.7 by jsr166, Thu Apr 14 23:16:10 2011 UTC

# Line 1 | Line 1
1   /*
2   * Written by Doug Lea with assistance from members of JCP JSR-166
3   * Expert Group and released to the public domain, as explained at
4 < * http://creativecommons.org/licenses/publicdomain
4 > * http://creativecommons.org/publicdomain/zero/1.0/
5   */
6  
7   package jsr166x;
# Line 50 | Line 50 | public class LinkedBlockingDeque<E>
50  
51      /** Doubly-linked list node class */
52      static final class Node<E> {
53 <        E item;
53 >        E item;
54          Node<E> prev;
55          Node<E> next;
56          Node(E x, Node<E> p, Node<E> n) {
# Line 524 | Line 524 | public class LinkedBlockingDeque<E>
524       * Variant of removeFirstOccurrence needed by iterator.remove.
525       * Searches for the node, not its contents.
526       */
527 <   boolean removeNode(Node<E> e) {
527 >    boolean removeNode(Node<E> e) {
528          lock.lock();
529          try {
530              for (Node<E> p = first; p != null; p = p.next) {
# Line 684 | Line 684 | public class LinkedBlockingDeque<E>
684              final ReentrantLock lock = LinkedBlockingDeque.this.lock;
685              lock.lock();
686              try {
687 <                next = (next == null)? first : next.next;
688 <                nextItem = (next == null)? null : next.item;
687 >                next = (next == null) ? first : next.next;
688 >                nextItem = (next == null) ? null : next.item;
689              } finally {
690                  lock.unlock();
691              }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines