Package com.vaadin.ui
Class Upload.FinishedEvent
- java.lang.Object
-
- java.util.EventObject
-
- com.vaadin.event.ConnectorEvent
-
- com.vaadin.ui.Component.Event
-
- com.vaadin.ui.Upload.FinishedEvent
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
Upload.FailedEvent,Upload.SucceededEvent
- Enclosing class:
- Upload
public static class Upload.FinishedEvent extends Component.Event
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.- Since:
- 3.0
- Author:
- Vaadin Ltd.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FinishedEvent(Upload source, java.lang.String filename, java.lang.String mimeType, long length)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetFilename()Gets the file name.longgetLength()Gets the length of the file.java.lang.StringgetMIMEType()Gets the MIME Type of the file.UploadgetUpload()Uploads where the event occurred.-
Methods inherited from class com.vaadin.ui.Component.Event
getComponent
-
Methods inherited from class com.vaadin.event.ConnectorEvent
getConnector
-
-
-
-
Constructor Detail
-
FinishedEvent
public FinishedEvent(Upload source, java.lang.String filename, java.lang.String mimeType, long length)
- Parameters:
source- the source of the file.filename- the received file name.mimeType- the MIME type of the received file.length- the length of the received file.
-
-
Method Detail
-
getUpload
public Upload getUpload()
Uploads where the event occurred.- Returns:
- the Source of the event.
-
getFilename
public java.lang.String getFilename()
Gets the file name.- Returns:
- the filename.
-
getMIMEType
public java.lang.String getMIMEType()
Gets the MIME Type of the file.- Returns:
- the MIME type.
-
getLength
public long getLength()
Gets the length of the file.- Returns:
- the length.
-
-