FormData class
Used to generate form data.
Properties
-
body
→ List<
int> -
Actual body of the form-data.
no setter
- boundary ↔ String
-
Boundary used in the form data.
getter/setter pair
- contentLength → int
-
Content-Length header value.
no setter
- contentType → String
-
Content-Type header value including the boundary.
no setter
- encoding → Encoding
-
Encoding used in converting String to List<int>. Defaults to
utf8
.final - hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
add(
String name, dynamic value) → void -
Add a field
name
to the form data. -
addBytes(
String name, List< int> bytes, {String? contentType, String? filename}) → void -
Add a field
name
to the form data. -
addFile(
String name, String filePath, {String? contentType, String? filename}) → void -
Add a field
name
to the form data. -
getHeaders(
) → Map< String, String> - Gets custom headers for multpart form.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited