Interface HasActions

All Known Subinterfaces:
EntityMultiPickerComponent<E>, EntityPickerComponent<E>, FragmentActions, PickerComponent<V>, ViewActions
All Known Implementing Classes:
ComboBoxPicker, DataGrid, EntityComboBox, EntityPicker, FragmentActionsImpl, GenericFilter, JmixGrid, JmixKanban, JmixMultiSelectComboBoxPicker, JmixMultiValuePicker, JmixTreeGrid, JmixValuePicker, Kanban, MultiSelectComboBoxPicker, MultiValuePicker, TreeDataGrid, ValuePicker, ValuePickerBase, ViewActionsImpl

public interface HasActions
Interface to be implemented by UI components containing Actions.
  • Method Details

    • addAction

      default void addAction(Action action)
      Add an action to the component.
      Parameters:
      action - action to add
    • addAction

      void addAction(Action action, int index)
      Add an action to the component at the specified index.
      Parameters:
      action - action to add
      index - index at which the specified action is to be added
    • removeAction

      void removeAction(Action action)
      Removes the action from the component.
      Parameters:
      action - action to remove
    • removeAction

      default void removeAction(String id)
      Removes the action with the given id. If there is no action with given id, nothing happens.
      Parameters:
      id - id of the action to remove
    • removeAllActions

      default void removeAllActions()
      Remove all actions from the component
    • getActions

      Collection<Action> getActions()
      Returns:
      unmodifiable collection of actions
    • getAction

      @Nullable Action getAction(String id)
      Returns an action with passed id.
      Parameters:
      id - id of the action to find
      Returns:
      an action by its id, or null if not found