java.lang.Object
org.jfree.data.general.AbstractDataset
org.jfree.data.general.DefaultValueDataset
- All Implemented Interfaces:
ObjectInputValidation
,Serializable
,Cloneable
,PublicCloneable
,Dataset
,ValueDataset
,Value
public class DefaultValueDataset
extends AbstractDataset
implements ValueDataset, Cloneable, PublicCloneable, Serializable
A dataset that stores a single value (that is possibly
null
).
This class provides a default implementation of the ValueDataset
interface.- See Also:
-
Constructor Summary
ConstructorDescriptionConstructs a new dataset, initially empty.DefaultValueDataset
(double value) Creates a new dataset with the specified value.DefaultValueDataset
(Number value) Creates a new dataset with the specified value. -
Method Summary
Methods inherited from class org.jfree.data.general.AbstractDataset
addChangeListener, clone, fireDatasetChanged, getGroup, getNotify, hasListener, notifyListeners, removeChangeListener, setGroup, setNotify, validateObject
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jfree.data.general.Dataset
addChangeListener, getGroup, removeChangeListener, setGroup
Methods inherited from interface org.jfree.chart.util.PublicCloneable
clone
-
Constructor Details
-
DefaultValueDataset
public DefaultValueDataset()Constructs a new dataset, initially empty. -
DefaultValueDataset
public DefaultValueDataset(double value) Creates a new dataset with the specified value.- Parameters:
value
- the value.
-
DefaultValueDataset
Creates a new dataset with the specified value.- Parameters:
value
- the initial value (null
permitted).
-
-
Method Details
-
getValue
Returns the value. -
setValue
Sets the value and sends aDatasetChangeEvent
to all registered listeners.- Parameters:
value
- the new value (null
permitted).
-
equals
Tests this dataset for equality with an arbitrary object. -
hashCode
public int hashCode()Returns a hash code.
-