Class FragmentedDataSet

    • Field Detail

      • dataCount

        protected int dataCount
      • list

        protected final java.util.ArrayList<DataSet> list
    • Constructor Detail

      • FragmentedDataSet

        public FragmentedDataSet​(java.lang.String name)
        Parameters:
        name - data set name
    • Method Detail

      • add

        public void add​(DataSet set)
        Parameters:
        set - new data set to be added to list
      • add

        public void add​(double[] xValues,
                        double[] yValues)
        adds new custom x and y array values (internally generates a new DataSet)
        Parameters:
        xValues - new X coordinates
        yValues - new Y coordinates
      • clear

        public void clear()
        clears all sub-dataset references
      • getDataCount

        public int getDataCount()
        Description copied from interface: DataSet
        Get the number of data points in the data set.
        Specified by:
        getDataCount in interface DataSet
        Returns:
        the number of data points
      • getDatasetCount

        public int getDatasetCount()
        Returns:
        number of sub-datasets
      • getDatasets

        public java.util.Collection<DataSet> getDatasets()
        Returns:
        sub-datasets
      • getStyle

        public java.lang.String getStyle​(int i)
        Description copied from class: AbstractDataSet
        A string representation of the CSS style associated with this specific DataSet data point. @see #getStyle()
        Specified by:
        getStyle in interface DataSet
        Overrides:
        getStyle in class AbstractDataSet<FragmentedDataSet>
        Parameters:
        i - the index of the specific data point
        Returns:
        user-specific data set style description (ie. may be set by user)
      • get

        public double get​(int dimIndex,
                          int index)
        Description copied from interface: DataSet
        Gets the x value of the data point with the index i
        Specified by:
        get in interface DataSet
        Parameters:
        dimIndex - the dimension index (ie. '0' equals 'X', '1' equals 'Y')
        index - data point index
        Returns:
        the x value
      • set

        public DataSet set​(DataSet other,
                           boolean copy)
        Specified by:
        set in interface DataSet
        Parameters:
        other - Other DataSet to copy into this DataSet
        copy - true: perform a deep copy (default), false: reuse the other dataset's internal data structures (if applicable)
        Returns:
        itself (fluent design) -- N.B. existing update listener are preserved