/** * Updates the x-values for all the series in the dataset. */ public void updateXPoints() { this.propagateEvents = false; for (int s = 0; s < this.data.size(); s++) { updateXPoints((XYSeries) this.data.get(s)); } if (this.autoPrune) { prune(); } this.propagateEvents = true; }
/** * Updates the x-values for all the series in the dataset. */ public void updateXPoints() { this.propagateEvents = false; for (int s = 0; s < this.data.size(); s++) { updateXPoints((XYSeries) this.data.get(s)); } if (this.autoPrune) { prune(); } this.propagateEvents = true; }
/** * Removes a series from the collection and sends a * {@link DatasetChangeEvent} to all registered listeners. * * @param series the series (zero based index). */ public void removeSeries(int series) { // check arguments... if ((series < 0) || (series > getSeriesCount())) { throw new IllegalArgumentException("Index outside valid range."); } // fetch the series, remove the change listener, then remove the series. XYSeries s = (XYSeries) this.data.get(series); s.removeChangeListener(this); this.data.remove(series); if (this.data.isEmpty()) { this.xPoints.clear(); } else if (this.autoPrune) { prune(); } fireDatasetChanged(); }
/** * Removes a series from the collection and sends a * {@link DatasetChangeEvent} to all registered listeners. * * @param series the series (zero based index). */ public void removeSeries(int series) { // check arguments... if ((series < 0) || (series > getSeriesCount())) { throw new IllegalArgumentException("Index outside valid range."); } // fetch the series, remove the change listener, then remove the series. XYSeries s = (XYSeries) this.data.get(series); s.removeChangeListener(this); this.data.remove(series); if (this.data.size() == 0) { this.xPoints.clear(); } else if (this.autoPrune) { prune(); } fireDatasetChanged(); }