Class RowActionsManager<T>

java.lang.Object
com.flowingcode.vaadin.addons.easygrid.actions.RowActionsManager<T>
Type Parameters:
T - the grid bean type
All Implemented Interfaces:
Serializable

public class RowActionsManager<T> extends Object implements Serializable
Manages the row actions column for an EasyGrid. Maintains the list of registered EasyRowAction instances, the render style (inline buttons, an overflow menu, or a context menu; see RowActionsStyle), and delegates all visual concerns to a RowActionsRenderer.

A manager instance is created lazily, on first access through its grid wrapper. The instance itself is lightweight; the actions Grid.Column it manages is created lazily (on the first renderer update or getActionsColumn() call) and stays hidden until the first action is added.

Author:
Javier Godoy / Flowing Code
See Also:
  • Constructor Details

    • RowActionsManager

      public RowActionsManager(@NonNull @NonNull Grid<T> grid)
      Creates a new RowActionsManager for the given grid.
      Parameters:
      grid - the grid to manage row actions for
  • Method Details

    • setRenderer

      public void setRenderer(@NonNull @NonNull RowActionsRenderer<T> renderer)
      Replaces the active renderer. The current renderer is cleaned up via RowActionsRenderer.remove() before the new one is installed. A renderer rebuild is scheduled for the next beforeClientResponse cycle.
      Parameters:
      renderer - the new renderer to use