com.vaadin.flow.component.upload.

Class FileRejectedEvent

java.lang.Object
java.util.EventObject
com.vaadin.flow.component.ComponentEvent<Upload>
com.vaadin.flow.component.upload.FileRejectedEvent

All Implemented Interfaces:

Serializable

public class FileRejectedEvent extends ComponentEvent<Upload>

Sent when the file selected for upload doesn't meet the constraints specified on Upload

Author:

Vaadin Ltd.

See Also:

  • Constructor Details

    • FileRejectedEvent

      @Deprecated(since="24.4") public FileRejectedEvent(Upload source, String errorMessage)
      Deprecated.

      Creates a new event using the given source and indicator whether the event originated from the client side or the server side.

      Parameters:

      source - the source component

      errorMessage - the error message

    • FileRejectedEvent

      public FileRejectedEvent(Upload source, String errorMessage, String fileName)

      Creates a new event using the given source and indicator whether the event originated from the client side or the server side.

      Parameters:

      source - the source component

      errorMessage - the error message

      fileName - the rejected file name

  • Method Details

    • getErrorMessage

      public String getErrorMessage()

      Get the error message

      Returns:

      errorMessage

    • getFileName

      public String getFileName()

      Get the file name.

      Returns:

      file name