Class FGrid.CommitErrorEvent

java.lang.Object
java.util.EventObject
com.vaadin.flow.component.ComponentEvent<com.vaadin.flow.component.Component>
com.vaadin.featurepack.ui.Event
com.vaadin.featurepack.ui.FGrid.CommitErrorEvent
All Implemented Interfaces:
Serializable
Enclosing class:
FGrid

public static class FGrid.CommitErrorEvent extends Event
An event which is fired when saving the editor fails
See Also:
  • Constructor Details

  • Method Details

    • getCause

      public FieldGroup.CommitException getCause()
      Retrieves the cause of the failure
      Returns:
      the cause of the failure
    • getComponent

      public FGrid getComponent()
      Description copied from class: Event
      Gets the component where the event occurred.
      Overrides:
      getComponent in class Event
      Returns:
      the source component of the event
    • isValidationFailure

      public boolean isValidationFailure()
      Checks if validation exceptions caused this error
      Returns:
      true if the problem was caused by a validation error
    • addErrorColumn

      public void addErrorColumn(FGrid.Column column)
      Marks that an error indicator should be shown for the editor of a column.
      Parameters:
      column - the column to show an error for
    • getErrorColumns

      public Collection<FGrid.Column> getErrorColumns()
      Gets all the columns that have been marked as erroneous.
      Returns:
      an umodifiable collection of erroneous columns
    • getUserErrorMessage

      public String getUserErrorMessage()
      Gets the error message to show to the user.
      Returns:
      error message to show
    • setUserErrorMessage

      public void setUserErrorMessage(String userErrorMessage)
      Sets the error message to show to the user.
      Parameters:
      userErrorMessage - the user error message to set