com.vaadin.flow.component.upload.
Class FinishedEvent
- java.lang.Object
-
- java.util.EventObject
-
- com.vaadin.flow.component.ComponentEvent<Upload>
-
- com.vaadin.flow.component.upload.FinishedEvent
-
All Implemented Interfaces:
Direct Known Subclasses:
public class FinishedEvent extends ComponentEvent<Upload>
FinishedEvent is sent when the upload receives a file, regardless of whether the reception was successful or failed. If you wish to distinguish between the two cases, use either SucceededEvent or FailedEvent, which are both subclasses of the FinishedEvent.
Author:
Vaadin Ltd.
See Also:
-
-
Field Summary
-
Fields inherited from class java.util.EventObject
source
-
-
Constructor Summary
Constructors Constructor Description FinishedEvent​(Upload source, String fileName, String mimeType, long length)
Create an instance of the event.
-
Method Summary
All Methods Modifier and Type Method Description long
getContentLength()
Get the length of the file.
String
getFileName()
Get the file name.
String
getMIMEType()
Get the MIME Type of the file.
Upload
getUpload()
Upload where the event occurred.
-
Methods inherited from class com.vaadin.flow.component.ComponentEvent
getSource, isFromClient, unregisterListener
-
Methods inherited from class java.util.EventObject
toString
-
-
-
-
Method Detail
-
getUpload
public Upload getUpload()
Upload where the event occurred.
Returns:
the Source of the event
-
getFileName
public String getFileName()
Get the file name.
Returns:
the file name
-
getMIMEType
public String getMIMEType()
Get the MIME Type of the file.
Returns:
the MIME type
-
getContentLength
public long getContentLength()
Get the length of the file.
Returns:
the length
-
-