edu.brook.ascape.view
Class DataViewSelection
java.lang.Object
|
+--java.util.Observable
|
+--edu.brook.ascape.util.DataSelection
|
+--edu.brook.ascape.view.DataViewSelection
- public class DataViewSelection
- extends DataSelection
A group of data series which may be selected, and which provides a settable
SeriesView (and other view realted features, as needed) for each element in the backing data
group. Items are reachable through selection in index or directly.
- Since:
- 1.0
- Version:
- 1.2
- See Also:
- Serialized Form
|
Field Summary |
protected SeriesView[] |
seriesViews
An array mirroring selection that tracks selected seriesView |
|
Method Summary |
SeriesView |
getSelectedSeriesView(int index)
Return the seriesView for the selected series at the supplied index. |
SeriesView |
getSeriesView(int index)
Return the seriesView for the series at the supplied index. |
SeriesView |
getSeriesView(java.lang.String name)
Return the seriesView for the series with the given name in the data group. |
void |
setSelectedSeriesView(int index,
SeriesView seriesView)
Sets the seriesView for the selected series at the supplied index to the supplied seriesView. |
void |
setSeriesView(java.lang.String name,
SeriesView seriesView)
Sets the seriesView for the named series to the supplied seriesView. |
void |
update()
Updates the selection in response to a change in the data group. |
| Methods inherited from class edu.brook.ascape.util.DataSelection |
clearSelection,
clone,
getData,
getIndexOfSelectedIndex,
getMax,
getMin,
getSelectedIndexOf,
getSelectedName,
getSelectedSeries,
getSelectedSeriesData,
getSelectionSize,
isSelected,
isSelected,
selectAll,
setData,
setSelected,
setSelected,
setSelected,
update |
| Methods inherited from class java.util.Observable |
addObserver,
clearChanged,
countObservers,
deleteObserver,
deleteObservers,
hasChanged,
notifyObservers,
notifyObservers,
setChanged |
| Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
seriesViews
protected SeriesView[] seriesViews
- An array mirroring selection that tracks selected seriesView
DataViewSelection
public DataViewSelection()
update
public void update()
- Updates the selection in response to a change in the data group.
- Overrides:
- update in class DataSelection
getSeriesView
public SeriesView getSeriesView(java.lang.String name)
- Return the seriesView for the series with the given name in the data group.
- Parameters:
the - name of the series within the data group
setSeriesView
public void setSeriesView(java.lang.String name,
SeriesView seriesView)
- Sets the seriesView for the named series to the supplied seriesView.
- Parameters:
the - name of the series within the data groupseriesView - the seriesView to assign to the series
getSeriesView
public SeriesView getSeriesView(int index)
- Return the seriesView for the series at the supplied index.
- Parameters:
the - index of the series within the data group
getSelectedSeriesView
public SeriesView getSelectedSeriesView(int index)
- Return the seriesView for the selected series at the supplied index.
- Parameters:
the - index of the series within the selection
setSelectedSeriesView
public void setSelectedSeriesView(int index,
SeriesView seriesView)
- Sets the seriesView for the selected series at the supplied index to the supplied seriesView.
- Parameters:
the - index of the series within the selectionseriesView - the seriesView to assign to the series