Modifier and Type | Method and Description |
---|---|
String |
filename()
Return the original filename in the client's filesystem.
|
default reactor.core.publisher.Mono<Void> |
transferTo(File dest)
Convenience method to copy the content of the file in this part to the
given destination file.
|
reactor.core.publisher.Mono<Void> |
transferTo(Path dest)
Convenience method to copy the content of the file in this part to the
given destination file.
|
String filename()
Note: Please keep in mind this filename is supplied by the client and should not be used blindly. In addition to not using the directory portion, the file name could also contain characters such as ".." and others that can be used maliciously. It is recommended to not use this filename directly. Preferably generate a unique one and save this one one somewhere for reference, if necessary.
null
if not defined or not availabledefault reactor.core.publisher.Mono<Void> transferTo(File dest)
The default implementation delegates to transferTo(Path)
.
dest
- the target fileMono
with the result of the file transfer,
possibly IllegalStateException
if the part isn't a filetransferTo(Path)
reactor.core.publisher.Mono<Void> transferTo(Path dest)
dest
- the target fileMono
with the result of the file transfer,
possibly IllegalStateException
if the part isn't a filetransferTo(File)