Class SortHeaderLayer<T>

Type Parameters:
T - Type of the Beans in the backing data source.
All Implemented Interfaces:
ILayer, ILayerListener, IPersistable

public class SortHeaderLayer<T> extends AbstractLayerTransform implements IPersistable
Enables sorting of the data. Uses an ISortModel to do/track the sorting.
See Also:
  • Constructor Details

    • SortHeaderLayer

      public SortHeaderLayer(ILayer underlyingLayer, ISortModel sortModel)
    • SortHeaderLayer

      public SortHeaderLayer(ILayer underlyingLayer, ISortModel sortModel, boolean useDefaultConfiguration)
  • Method Details

    • getConfigLabelsByPosition

      public LabelStack getConfigLabelsByPosition(int columnPosition, int rowPosition)
      Description copied from interface: ILayer
      Returns the config labels for the cell at the given coordinates. Needed to retrieve the corresponding configurations out of the IConfigRegistry.
      Specified by:
      getConfigLabelsByPosition in interface ILayer
      getConfigLabelsByPosition in class AbstractLayerTransform
      columnPosition - The column position of the cell.
      rowPosition - The row position of the cell.
      adds a special configuration label to the stack taking into account the following:
      1. Is the column sorted ?
      2. What is the sort order of the column
      A special painter is registered against the above labels to render the sort arrows
    • getSortModel

      public ISortModel getSortModel()
      The ISortModel that is used to handle the sorting of the underlying data.
    • getProvidedLabels

      public Collection<String> getProvidedLabels()
      Specified by:
      getProvidedLabels in interface ILayer
      getProvidedLabels in class AbstractLayer
      The collection of labels that are provided by this layer.