Package com.teamdev.jxbrowser.net
Interface MultipartFormData.Pair
- Enclosing interface:
- MultipartFormData
public static interface MultipartFormData.Pair
A key-value pair that represents a segment of a multi-part form data. Can contain values
corresponding a form field content, an upload file content, etc.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the form content segment value as a file.default Stringkey()Returns a string that represents the form content segment key.static MultipartFormData.PairReturns thePairinstance for the givenkeyandvalue.static MultipartFormData.PairReturns thePairinstance for the givenkeyandvalue.Returns the form content segment value as a string.
-
Method Details
-
of
Returns thePairinstance for the givenkeyandvalue.The key-value pair that represents a segment of a multi-part form data. Can contain values corresponding a form field content, an upload file content, etc.
- Parameters:
key- the form content segment keyvalue- the string representing the form content segment value. Can be empty if thekeydoes not correspond to anyvalue. For example, an empty form field- Throws:
IllegalArgumentException- whenkeyis empty or blank
-
of
Returns thePairinstance for the givenkeyandvalue.The key-value pair that represents a segment of a multi-part form data. Can contain values corresponding a form field content, an upload file content, etc.
- Parameters:
key- the form content segment keyvalue- the segment value representing the file content- Throws:
IllegalArgumentException- whenkeyis empty
-
key
Returns a string that represents the form content segment key. -
stringValue
Returns the form content segment value as a string. -
fileValue
Returns the form content segment value as a file.
-