Class AssociativeData<KEY,VALUE>

java.lang.Object
io.deephaven.plot.datasets.data.AssociativeData<KEY,VALUE>
All Implemented Interfaces:
PlotExceptionCause, Serializable
Direct Known Subclasses:
AssociativeDataHashMap, AssociativeDataWithDefault, LiveAssociativeData

public abstract class AssociativeData<KEY,VALUE> extends Object implements PlotExceptionCause, Serializable
Dataset which has values associated with keys.
See Also:
  • Constructor Details

    • AssociativeData

      public AssociativeData(PlotInfo plotInfo)
      Parameters:
      plotInfo - plot information
  • Method Details

    • get

      public abstract VALUE get(KEY key)
      Gets the value associated with the key
      Parameters:
      key - key
      Returns:
      value associated with the key
    • isModifiable

      public abstract boolean isModifiable()
      Whether the dataset is modifiable.
      Returns:
      true if the dataset is modifiable, false if not
    • put

      public abstract void put(KEY key, VALUE value)
      Adds the key-value pair to the dataset.
      Parameters:
      key - key
      value - value
    • putAll

      public abstract <K extends KEY, V extends VALUE> void putAll(Map<K,V> values)
      Adds all key-value pairs in the map to the dataset.
      Type Parameters:
      K - type of the keys in values
      V - type of the values in values
      Parameters:
      values - keypair map
    • getPlotInfo

      public PlotInfo getPlotInfo()
      Specified by:
      getPlotInfo in interface PlotExceptionCause