public interface MultipartFileSpec
Modifier and Type | Method and Description |
---|---|
MultipartFormSpec |
add()
Add the file to the parent multipart form
|
MultipartFileSpec |
contentType(java.lang.String contentType)
Specify the content type
|
MultipartFileSpec |
data(byte[] data)
Specify the file contents
|
MultipartFileSpec |
data(java.lang.String data)
Specify the file contents
|
MultipartFileSpec |
encoding(java.lang.String encoding)
Specify the form field
|
MultipartFileSpec |
field(java.lang.String field)
Specify the form field
|
MultipartFileSpec |
name(java.lang.String name)
Specify the uploaded filename
|
MultipartFormSpec add()
Note: Must be called to include the file into the payload.
MultipartFileSpec contentType(java.lang.String contentType)
Required. Defaults to 'text/plain'.
MultipartFileSpec data(byte[] data)
Required. No default provided.
MultipartFileSpec data(java.lang.String data)
Required. No default provided.
Note: this value is encoded into a byte array using UTF-8
MultipartFileSpec encoding(java.lang.String encoding)
Optional. No default provided.
Valid options include BASE64, QUOTED-PRINTABLE, 8BIT, 7BIT, BINARY.
Custom encodings of the for X-
Note: Netty will need to understand this encoding scheme.
MultipartFileSpec field(java.lang.String field)
Required. Defaults to 'file'.
MultipartFileSpec name(java.lang.String name)
Required. Defaults to 'filename.txt'.