org.jfree.util

Class ShapeList

Implemented Interfaces:
Cloneable, Serializable

public class ShapeList
extends AbstractObjectList

A table of Shape objects.
Author:
David Gilbert

Field Summary

Fields inherited from class org.jfree.util.AbstractObjectList

DEFAULT_INITIAL_CAPACITY

Constructor Summary

ShapeList()
Creates a new list.

Method Summary

Object
clone()
Returns an independent copy of the list.
boolean
equals(Object o)
Tests the list for equality with another object (typically also a list).
Shape
getShape(int index)
Returns a Shape object from the list.
int
hashCode()
Returns a hash code value for the object.
void
setShape(int index, Shape shape)
Sets the Shape for an item in the list.

Methods inherited from class org.jfree.util.AbstractObjectList

clear, clone, equals, get, hashCode, indexOf, set, size

Constructor Details

ShapeList

public ShapeList()
Creates a new list.

Method Details

clone

public Object clone()
            throws CloneNotSupportedException
Returns an independent copy of the list.
Overrides:
clone in interface AbstractObjectList
Returns:
A clone.

equals

public boolean equals(Object o)
Tests the list for equality with another object (typically also a list).
Overrides:
equals in interface AbstractObjectList
Parameters:
o - the other object.
Returns:
A boolean.

getShape

public Shape getShape(int index)
Returns a Shape object from the list.
Parameters:
index - the index (zero-based).
Returns:
The object.

hashCode

public int hashCode()
Returns a hash code value for the object.
Overrides:
hashCode in interface AbstractObjectList
Returns:
the hashcode

setShape

public void setShape(int index,
                     Shape shape)
Sets the Shape for an item in the list. The list is expanded if necessary.
Parameters:
index - the index (zero-based).
shape - the Shape.