com.steema.teechart.styles
Class SeriesCollection

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.ArrayList
              extended by com.steema.teechart.styles.SeriesCollection
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.List, java.util.RandomAccess

public final class SeriesCollection
extends java.util.ArrayList

Title: SeriesCollection class

Description: The SeriesCollection class, a collection of Series objects, is manipulated via the TChart TChart.getSeries() method.

Copyright (c) 2005-2008 by Steema Software SL. All Rights Reserved.

Company: Steema Software SL

See Also:
TChart.getSeries(), Serialized Form

Field Summary
 IBaseChart chart
           
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
SeriesCollection()
           
SeriesCollection(IBaseChart c)
           
 
Method Summary
 boolean activeUseAxis()
           
 Series add(java.lang.Class type)
           
 Series add(Series s)
          Adds a new Series instance to Chart.
 void clear()
          Removes and disposes all Series.
 void clear(boolean dispose)
          Removes (and optionally disposes) all Series.
 void exchange(int series1, int series2)
          Changes the Series order, swapping one Series Z position with another.
 void fillSampleValues()
          Adds random values to all series in the collection to help visualize the Series.
 void fillSampleValues(int numValues)
          Adds the specified NumValues random points to all series in the collection.
 boolean getApplyZOrder()
          Sets multiple Series on same Chart in different Z spaces when true.
 IBaseChart getChart()
          Defines the Chart component.
 Series getSeries(int index)
           
 int indexOf(Series s)
          Returns the corresponding point index which has the specified Value.
 void insert(int index, Series s)
           
 void internalAdd(Series s)
           
 void moveTo(Series s, int index)
           
 void remove(Series s)
          Deletes the specified Series from the Chart list of series.
 void removeAllSeries()
          Removes all Series from the Chart but does not dispose of (destroy) them.
 void setApplyZOrder(boolean value)
          Sets multiple Series on same Chart in different Z spaces when true.
 void setChart(IBaseChart chart)
           
 void setSeries(int index, Series value)
           
 Series withTitle(java.lang.String title)
           
 
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, set, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList
 

Field Detail

chart

public transient IBaseChart chart
Constructor Detail

SeriesCollection

public SeriesCollection()

SeriesCollection

public SeriesCollection(IBaseChart c)
Method Detail

internalAdd

public void internalAdd(Series s)

add

public Series add(java.lang.Class type)
           throws java.lang.InstantiationException,
                  java.lang.IllegalAccessException
Throws:
java.lang.InstantiationException
java.lang.IllegalAccessException

add

public Series add(Series s)
Adds a new Series instance to Chart.

Parameters:
s - Series The Series instance to add.
Returns:
Series The same Series.

getSeries

public Series getSeries(int index)

setSeries

public void setSeries(int index,
                      Series value)

insert

public void insert(int index,
                   Series s)

moveTo

public void moveTo(Series s,
                   int index)

indexOf

public int indexOf(Series s)
Returns the corresponding point index which has the specified Value.

Parameters:
s - Series
Returns:
int

withTitle

public Series withTitle(java.lang.String title)

remove

public void remove(Series s)
Deletes the specified Series from the Chart list of series.

Parameters:
s - Series

removeAllSeries

public void removeAllSeries()
Removes all Series from the Chart but does not dispose of (destroy) them.


exchange

public void exchange(int series1,
                     int series2)
Changes the Series order, swapping one Series Z position with another.
The Chart repaints to reflect the new Series order.
It accesses TChart.SeriesList method.

Parameters:
series1 - int
series2 - int

clear

public void clear(boolean dispose)
Removes (and optionally disposes) all Series.

Parameters:
dispose - boolean

clear

public void clear()
Removes and disposes all Series.

Specified by:
clear in interface java.util.Collection
Specified by:
clear in interface java.util.List
Overrides:
clear in class java.util.ArrayList

getChart

public IBaseChart getChart()
Defines the Chart component.

Returns:
IBaseChart

activeUseAxis

public boolean activeUseAxis()

getApplyZOrder

public boolean getApplyZOrder()
Sets multiple Series on same Chart in different Z spaces when true.
Run-time only.
It's valid only when TChart.View3D is true and when there's more than one Series in the same chart.
When false, all Series are drawn using the full Chart Z space. The Chart output can be confusing if Series overlap.
Default value: true

Returns:
boolean

setApplyZOrder

public void setApplyZOrder(boolean value)
Sets multiple Series on same Chart in different Z spaces when true.
Run-time only.
Default value: true

Parameters:
value - boolean

fillSampleValues

public void fillSampleValues()
Adds random values to all series in the collection to help visualize the Series.
Each series class determines how many random points to add.


fillSampleValues

public void fillSampleValues(int numValues)
Adds the specified NumValues random points to all series in the collection.

Parameters:
numValues - int the number of sample values to add.

setChart

public void setChart(IBaseChart chart)