de.aitools.iv.graphdrawing.datastructures
Class DoubleLinkedList

java.lang.Object
  extended by de.aitools.iv.graphdrawing.datastructures.DoubleLinkedList

public class DoubleLinkedList
extends java.lang.Object

A implementation of a double linked list, that permits null-pionter.

Author:
bigben@upb.de

Nested Class Summary
 class DoubleLinkedList.LinkedListIterator
          Inner Iterator-Class
 
Constructor Summary
DoubleLinkedList()
           
 
Method Summary
 DoubleLinkedListElement add(java.lang.Object obj)
          adds a new element to this list
 java.util.Iterator iterator()
           
 void remove(DoubleLinkedListElement elem)
          remove an element from this list
 int size()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DoubleLinkedList

public DoubleLinkedList()
Method Detail

size

public int size()
Returns:
the number of elements in this list

add

public DoubleLinkedListElement add(java.lang.Object obj)
adds a new element to this list

Parameters:
obj - the object to be encapsulated in the list-element
Returns:
the list-element, which contains the element

remove

public void remove(DoubleLinkedListElement elem)
remove an element from this list

Parameters:
elem - the list-element, which contains the element-object

iterator

public java.util.Iterator iterator()
Returns:
an Iterator, initialized with the first list-element