at.jku.ssw
Class LinkedList

java.lang.Object
  extended by at.jku.ssw.List
      extended by at.jku.ssw.LinkedList

public class LinkedList
extends List

A linked list of characters.


Constructor Summary
LinkedList()
           
 
Method Summary
 void add(char value)
          Appends the value to the end of this list.
 void add(int index, char value)
          Inserts the value at position index.
 char get(int index)
          Returns the value at position index.
 int indexOf(char value)
          Returns the index of the first occurrence of the value.
 Iterator iterator()
          Returns an iterator of the values in this list.
 char remove(int index)
          Removes the value at position index.
 int size()
          Returns the number of values in this list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinkedList

public LinkedList()
Method Detail

add

public void add(char value)
Appends the value to the end of this list.

Specified by:
add in class List

add

public void add(int index,
                char value)
Inserts the value at position index.

Specified by:
add in class List

get

public char get(int index)
Returns the value at position index.

Specified by:
get in class List

remove

public char remove(int index)
Removes the value at position index.

Specified by:
remove in class List

indexOf

public int indexOf(char value)
Returns the index of the first occurrence of the value.

Specified by:
indexOf in class List

size

public int size()
Returns the number of values in this list.

Specified by:
size in class List

iterator

public Iterator iterator()
Returns an iterator of the values in this list.

Specified by:
iterator in class List