Package akka.http.javadsl.model
Class FormData
- java.lang.Object
-
- akka.http.javadsl.model.FormData
-
public final class FormData extends java.lang.Object
Simple model for `application/x-www-form-urlencoded` form data.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static FormData
create(akka.japi.Pair<java.lang.String,java.lang.String>... params)
Creates the FormData from the given parameters.static FormData
create(java.lang.Iterable<akka.japi.Pair<java.lang.String,java.lang.String>> params)
Creates a FormData from the given parameters.static FormData
create(java.util.Map<java.lang.String,java.lang.String> params)
Creates the FormData from the given parameters.RequestEntity
toEntity()
Converts this FormData to a RequestEntity using UTF8 encoding.RequestEntity
toEntity(HttpCharset charset)
Deprecated.FormData always uses charset UTF-8 without appending the charset to 'Content-Type: application/x-www-form-urlencoded', use toEntity() instead.
-
-
-
Field Detail
-
EMPTY
public static final FormData EMPTY
Returns empty FormData.
-
-
Constructor Detail
-
FormData
public FormData(Query fields)
-
-
Method Detail
-
toEntity
public RequestEntity toEntity()
Converts this FormData to a RequestEntity using UTF8 encoding.
-
toEntity
@Deprecated public RequestEntity toEntity(HttpCharset charset)
Deprecated.FormData always uses charset UTF-8 without appending the charset to 'Content-Type: application/x-www-form-urlencoded', use toEntity() instead.Converts this FormData to a RequestEntity using the given encoding.
-
create
@SafeVarargs public static FormData create(akka.japi.Pair<java.lang.String,java.lang.String>... params)
Creates the FormData from the given parameters.
-
create
public static FormData create(java.util.Map<java.lang.String,java.lang.String> params)
Creates the FormData from the given parameters.
-
create
public static FormData create(java.lang.Iterable<akka.japi.Pair<java.lang.String,java.lang.String>> params)
Creates a FormData from the given parameters.
-
-