Class DoubleLinkedList<T extends DoubleLinkedListNode>
java.lang.Object
org.apache.commons.jcs3.utils.struct.DoubleLinkedList<T>
This is a generic thread safe double linked list. It's very simple and all the operations are so
 quick that course grained synchronization is more than acceptable.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidAdds a new node to the start of the link list.voidAdds a new node to the end of the link list.voidDump the cache entries from first to list for debugging.getFirst()Removes the specified node from the link list.getLast()Returns the last node from the link list, if there are any nodes.voidMoves an existing node to the start of the link list.voidMoves an existing node to the end of the link list.booleanRemoves the specified node from the link list.voidRemove all of the elements from the linked list implementation.Removes the specified node from the link list.intsize()Returns the size of the list.
- 
Constructor Details- 
DoubleLinkedListpublic DoubleLinkedList()Default constructor.
 
- 
- 
Method Details- 
addLastAdds a new node to the end of the link list.- Parameters:
- me- The feature to be added to the Last
 
- 
addFirstAdds a new node to the start of the link list.- Parameters:
- me- The feature to be added to the First
 
- 
getLastReturns the last node from the link list, if there are any nodes.- Returns:
- The last node.
 
- 
getFirstRemoves the specified node from the link list.- Returns:
- DoubleLinkedListNode, the first node.
 
- 
makeFirstMoves an existing node to the start of the link list.- Parameters:
- ln- The node to set as the head.
 
- 
makeLastMoves an existing node to the end of the link list.- Parameters:
- ln- The node to set as the head.
 
- 
removeAllRemove all of the elements from the linked list implementation.
- 
removeRemoves the specified node from the link list.- Parameters:
- me- Description of the Parameter
- Returns:
- true if an element was removed.
 
- 
removeLastRemoves the specified node from the link list.- Returns:
- The last node if there was one to remove.
 
- 
sizeReturns the size of the list.- Returns:
- int
 
- 
debugDumpEntriesDump the cache entries from first to list for debugging.
 
-