Example usage for org.jfree.data.time TimeSeries removeVetoableChangeListener

List of usage examples for org.jfree.data.time TimeSeries removeVetoableChangeListener

Introduction

In this page you can find the example usage for org.jfree.data.time TimeSeries removeVetoableChangeListener.

Prototype

public void removeVetoableChangeListener(VetoableChangeListener listener) 

Source Link

Document

Removes a vetoable property change listener from the series.

Usage

From source file:org.jfree.data.time.TimeSeriesCollection.java

/**
 * Removes all the series from the collection and sends a
 * {@link DatasetChangeEvent} to all registered listeners.
 */// w  w w.j av  a  2 s.  c  o  m
public void removeAllSeries() {

    // deregister the collection as a change listener to each series in the
    // collection
    for (int i = 0; i < this.data.size(); i++) {
        TimeSeries series = (TimeSeries) this.data.get(i);
        series.removeChangeListener(this);
        series.removeVetoableChangeListener(this);
    }

    // remove all the series from the collection and notify listeners.
    this.data.clear();
    fireDatasetChanged();

}

From source file:org.jfree.data.time.TimeSeriesCollection.java

/**
 * Removes the specified series from the collection and sends a
 * {@link DatasetChangeEvent} to all registered listeners.
 *
 * @param series  the series (<code>null</code> not permitted).
 *//* www.  ja  va  2  s .  c o  m*/
public void removeSeries(TimeSeries series) {
    ParamChecks.nullNotPermitted(series, "series");
    this.data.remove(series);
    series.removeChangeListener(this);
    series.removeVetoableChangeListener(this);
    fireDatasetChanged();
}