Class DefaultValueDataset

    • Field Detail

      • serialVersionUID

        private static final long serialVersionUID
        For serialization.
        See Also:
        Constant Field Values
      • value

        private java.lang.Number value
        The value.
    • Constructor Detail

      • 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

        public DefaultValueDataset​(java.lang.Number value)
        Creates a new dataset with the specified value.
        Parameters:
        value - the initial value (null permitted).
    • Method Detail

      • getValue

        public java.lang.Number getValue()
        Returns the value.
        Specified by:
        getValue in interface Value
        Returns:
        The value (possibly null).
      • setValue

        public void setValue​(java.lang.Number value)
        Sets the value and sends a DatasetChangeEvent to all registered listeners.
        Parameters:
        value - the new value (null permitted).
      • equals

        public boolean equals​(java.lang.Object obj)
        Tests this dataset for equality with an arbitrary object.
        Overrides:
        equals in class AbstractDataset
        Parameters:
        obj - the object (null permitted).
        Returns:
        A boolean.
      • hashCode

        public int hashCode()
        Returns a hash code.
        Overrides:
        hashCode in class AbstractDataset
        Returns:
        A hash code.