org.apache.commons.collections.primitives

Class RandomAccessDoubleList

public abstract class RandomAccessDoubleList extends AbstractDoubleCollection implements DoubleList

Abstract base class for DoubleLists backed by random access structures like arrays.

Read-only subclasses must override RandomAccessDoubleList and RandomAccessDoubleList. Mutable subclasses should also override RandomAccessDoubleList. Variably-sized subclasses should also override RandomAccessDoubleList and RandomAccessDoubleList. All other methods have at least some base implementation derived from these. Subclasses may choose to override these methods to provide a more efficient implementation.

Since: Commons Primitives 1.0

Version: $Revision: 1.3 $ $Date: 2003/10/16 20:49:36 $

Author: Rodney Waldhoff

Nested Class Summary
static classRandomAccessDoubleList.ComodChecker
protected static classRandomAccessDoubleList.RandomAccessDoubleListIterator
protected static classRandomAccessDoubleList.RandomAccessDoubleSubList
Field Summary
int_modCount
Constructor Summary
protected RandomAccessDoubleList()
Constructs an empty list.
Method Summary
voidadd(int index, double element)
Unsupported in this implementation.
booleanadd(double element)
booleanaddAll(int index, DoubleCollection collection)
booleanequals(Object that)
abstract doubleget(int index)
protected intgetModCount()
Get my count of structural modifications.
inthashCode()
protected voidincrModCount()
Increment my count of structural modifications.
intindexOf(double element)
DoubleIteratoriterator()
intlastIndexOf(double element)
DoubleListIteratorlistIterator()
DoubleListIteratorlistIterator(int index)
doubleremoveElementAt(int index)
Unsupported in this implementation.
doubleset(int index, double element)
Unsupported in this implementation.
abstract intsize()
DoubleListsubList(int fromIndex, int toIndex)
StringtoString()

Field Detail

_modCount

private int _modCount

Constructor Detail

RandomAccessDoubleList

protected RandomAccessDoubleList()
Constructs an empty list.

Method Detail

add

public void add(int index, double element)
Unsupported in this implementation.

Throws: UnsupportedOperationException since this method is not supported

add

public boolean add(double element)

addAll

public boolean addAll(int index, DoubleCollection collection)

equals

public boolean equals(Object that)

get

public abstract double get(int index)

getModCount

protected int getModCount()
Get my count of structural modifications.

hashCode

public int hashCode()

incrModCount

protected void incrModCount()
Increment my count of structural modifications.

indexOf

public int indexOf(double element)

iterator

public DoubleIterator iterator()

lastIndexOf

public int lastIndexOf(double element)

listIterator

public DoubleListIterator listIterator()

listIterator

public DoubleListIterator listIterator(int index)

removeElementAt

public double removeElementAt(int index)
Unsupported in this implementation.

Throws: UnsupportedOperationException since this method is not supported

set

public double set(int index, double element)
Unsupported in this implementation.

Throws: UnsupportedOperationException since this method is not supported

size

public abstract int size()

subList

public DoubleList subList(int fromIndex, int toIndex)

toString

public String toString()
Copyright (c) 2002-2003 - Apache Software Foundation