接口 Multipart
- 所有已知子接口:
MultipartFile
public interface Multipart
Representation for a part in a "multipart/form-data" request.
The origin of a multipart request may be a browser form in which case each
part is either a FormField or a MultipartFile.
Multipart requests may also be used outside of a browser for data of any content type (e.g. JSON, PDF, etc).
- 从以下版本开始:
- 4.0 2022/4/28 22:04
- 作者:
- Harry Yang
- 另请参阅:
-
方法概要
修饰符和类型方法说明voiddelete()Deletes the underlying storage for a file item, including deleting any associated temporary disk file.Return the headers for the specified part of the multipart request.getName()Gets the name of this part.getValue()Return the form field value.booleanDetermines whether or not aMultipartinstance represents a simple form field.
-
方法详细资料
-
getName
String getName()Gets the name of this part.- 返回:
- The name of this part as a
String
-
getValue
String getValue()Return the form field value. -
isFormField
boolean isFormField()Determines whether or not aMultipartinstance represents a simple form field.- 返回:
trueif the instance represents a simple form field;falseif it represents an uploaded file.
-
getHeaders
HttpHeaders getHeaders()Return the headers for the specified part of the multipart request.If the underlying implementation supports access to part headers, then all headers are returned. Otherwise, e.g. for a file upload, the returned headers may expose a 'Content-Type' if available.
-
delete
Deletes the underlying storage for a file item, including deleting any associated temporary disk file.- 抛出:
IOException- if an error occurs.
-