balance_http library
Support for doing something awesome.
More dartdocs go here.
Classes
- BalanceClient
- The interface for HTTP clients that take care of maintaining persistent connections across multiple requests to the same server.
- BalanceRequest
- The base class for HTTP requests.
- Request
- An HTTP request where the entire request body is known in advance.
Functions
-
delete(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding, Duration? timeout}) → Future<Response> - Sends an HTTP DELETE request with the given headers to the given URL.
-
get(
Uri url, {Map< String, String> ? headers, Duration? timeout}) → Future<Response> - Sends an HTTP GET request with the given headers to the given URL.
-
head(
Uri url, {Map< String, String> ? headers, Duration? timeout}) → Future<Response> - Sends an HTTP HEAD request with the given headers to the given URL.
-
patch(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding, Duration? timeout}) → Future<Response> - Sends an HTTP PATCH request with the given headers and body to the given URL.
-
post(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding, Duration? timeout}) → Future<Response> - Sends an HTTP POST request with the given headers and body to the given URL.
-
put(
Uri url, {Map< String, String> ? headers, Object? body, Encoding? encoding, Duration? timeout}) → Future<Response> - Sends an HTTP PUT request with the given headers and body to the given URL.
-
read(
Uri url, {Map< String, String> ? headers, Duration? timeout}) → Future<String> - Sends an HTTP GET request with the given headers to the given URL and returns a Future that completes to the body of the response as a String.
-
readBytes(
Uri url, {Map< String, String> ? headers, Duration? timeout}) → Future<Uint8List> - Sends an HTTP GET request with the given headers to the given URL and returns a Future that completes to the body of the response as a list of bytes.