com.vaadin.flow.component.upload.receivers.
Class MultiFileMemoryBuffer
All Implemented Interfaces:
Basic multi file in memory file receiver implementation.
See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetFileData
(String fileName) Get file data for upload with file name.
getFiles()
Get the files in memory for this buffer.
getInputStream
(String filename) Get the input stream for file with filename.
getOutputBuffer
(String fileName) Get the output stream for file.
receiveUpload
(String fileName, String MIMEType) Invoked when a new upload arrives.
-
Constructor Details
-
MultiFileMemoryBuffer
public MultiFileMemoryBuffer()
-
-
Method Details
-
receiveUpload
Description copied from interface:
Receiver
Invoked when a new upload arrives.
Specified by:
receiveUpload
in interfaceReceiver
Parameters:
fileName
- the desired filename of the upload, usually as specified by the clientMIMEType
- the MIME type of the uploaded fileReturns:
stream to which the uploaded file should be written
-
getFiles
Get the files in memory for this buffer.
Returns:
files in memory
-
getFileData
Get file data for upload with file name.
Parameters:
fileName
- file name to get upload data forReturns:
file data for filename or null if not found
-
getOutputBuffer
Get the output stream for file.
Parameters:
fileName
- name of file to get stream forReturns:
file output stream or empty stream if no file found
-
getInputStream
Get the input stream for file with filename.
Parameters:
filename
- name of file to get input stream forReturns:
input stream for file or empty stream if file not found
-