IOClient class
A dart:io
-based HTTP Client.
- Inheritance
-
- Object
- BaseClient
- IOClient
Constructors
- IOClient({HttpClient? httpClient, Pipeline? pipeline})
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
close(
) → Future< void> -
Closes the client and cleans up any associated resources.
override
-
delete(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding}) → Future<Response> -
Sends an HTTP DELETE request to the specified
url
.inherited -
get(
Uri url, {Map< String, String> ? headers}) → Future<Response> -
Sends an HTTP GET request to the specified
url
.inherited -
head(
Uri url, {Map< String, String> ? headers}) → Future<Response> -
Sends an HTTP HEAD request to the specified
url
.inherited -
makeRequest(
String method, Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding}) → Request -
Creates a new
Request
instance with the given parameters.override -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
patch(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding}) → Future<Response> -
Sends an HTTP PATCH request to the specified
url
.inherited -
post(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding}) → Future<Response> -
Sends an HTTP POST request to the specified
url
.inherited -
put(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding}) → Future<Response> -
Sends an HTTP PUT request to the specified
url
.inherited -
read(
Uri url, {Map< String, String> ? headers}) → Future<String> -
Sends an HTTP GET request to the specified
url
and returns the body as a String.inherited -
readBytes(
Uri url, {Map< String, String> ? headers}) → Future<Uint8List> -
Sends an HTTP GET request to the specified
url
and returns the body as a Uint8List.inherited -
send(
Request request) → Future< Response> -
Sends the given
request
and returns the response.override -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited