Package io.vertx.ext.web.multipart
Interface MultipartForm
-
- All Superinterfaces:
Iterable<FormDataPart>
public interface MultipartForm extends Iterable<FormDataPart>
A multipart form.- Author:
- Julien Viet
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description MultipartFormattribute(String name, String value)Add an attribute form data part.MultipartFormbinaryFileUpload(String name, String filename, Buffer content, String mediaType)Add a binary file upload form data part.MultipartFormbinaryFileUpload(String name, String filename, String pathname, String mediaType)Add a binary file upload form data part.static MultipartFormcreate()CharsetgetCharset()MultipartFormsetCharset(String charset)Set thecharsetto use when encoding the form.MultipartFormsetCharset(Charset charset)Set thecharsetto use when encoding the form.MultipartFormtextFileUpload(String name, String filename, Buffer content, String mediaType)Add a text file upload form data part.MultipartFormtextFileUpload(String name, String filename, String pathname, String mediaType)Add a text file upload form data part.-
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
-
-
-
Method Detail
-
create
static MultipartForm create()
- Returns:
- a multipart form instance
-
setCharset
MultipartForm setCharset(String charset)
Set thecharsetto use when encoding the form. The default charset isStandardCharsets.UTF_8.- Parameters:
charset- the charset to use- Returns:
- a reference to this, so the API can be used fluently
-
setCharset
MultipartForm setCharset(Charset charset)
Set thecharsetto use when encoding the form. The default charset isStandardCharsets.UTF_8.- Parameters:
charset- the charset to use- Returns:
- a reference to this, so the API can be used fluently
-
getCharset
Charset getCharset()
- Returns:
- the charset to use when encoding the form
-
attribute
MultipartForm attribute(String name, String value)
Add an attribute form data part.- Parameters:
name- the name of the attributevalue- the value of the attribute- Returns:
- a reference to this, so the API can be used fluently
-
textFileUpload
MultipartForm textFileUpload(String name, String filename, String pathname, String mediaType)
Add a text file upload form data part.- Parameters:
name- name of the parameterfilename- filename of the filepathname- the pathname of the filemediaType- the MIME type of the file- Returns:
- a reference to this, so the API can be used fluently
-
textFileUpload
MultipartForm textFileUpload(String name, String filename, Buffer content, String mediaType)
Add a text file upload form data part.- Parameters:
name- name of the parameterfilename- filename of the filecontent- the content of the filemediaType- the MIME type of the file- Returns:
- a reference to this, so the API can be used fluently
-
binaryFileUpload
MultipartForm binaryFileUpload(String name, String filename, String pathname, String mediaType)
Add a binary file upload form data part.- Parameters:
name- name of the parameterfilename- filename of the filepathname- the pathname of the filemediaType- the MIME type of the file- Returns:
- a reference to this, so the API can be used fluently
-
binaryFileUpload
MultipartForm binaryFileUpload(String name, String filename, Buffer content, String mediaType)
Add a binary file upload form data part.- Parameters:
name- name of the parameterfilename- filename of the filecontent- the content of the filemediaType- the MIME type of the file- Returns:
- a reference to this, so the API can be used fluently
-
-