http_api library
Classes
- ApiLink
- An abstract class that lets you create your own link
- BaseApi
-
This class is a simple wrapper around
http
library it's main target is to handle auth headers. - CacheKey
- CacheManager
- Base class for implementing cachce managers.
- DataType
- DebugLink
- To create own dev-only ApiLink, extend this class. DebugLinks will NOT be present in release builds. They are ignored by ApiLink.chain method.
- ExceptionLink
- FileField
-
Represents File that can be attached to
BaseApiRequest
so can be sent to API with FormDataRequest - FileFieldWithFile
- FileFieldWithStream
- FormData
- A class to create readable "multipart/form-data" streams. It can be used to submit forms and file uploads to http server.
- FormDataRequest
-
A
multipart/form-data
request. - HeadersMapperLink
-
This ApiLink takes headers specified by
headersToMap
argument from response headers and then put to the next request headers. - HttpLink
- HttpMethod
- HttpProgressRequest
- InMemoryCache
- Simplest CacheManager implementation that stores ApiResponses in memory. The cache will be cleared, along with api 'dispose' method invocation.
- LoggerLink
- LoggerLink is DebugLink that prints request details to console.
- MediaType
- A class representing an HTTP media type, as used in Accept and Content-Type headers.
- ObjectId
- ObjectId
- Request
- Response
Mixins
-
Cache<
T extends CacheManager> - Base class for implementing cache providers.
- Serializable
Constants
-
boundaryCharacters
→ const List<
int> - All character codes that are valid in multipart boundaries.
Functions
-
isPlainAscii(
String string) → bool -
Returns whether
string
is composed entirely of ASCII-compatible characters.
Typedefs
-
NextFunction
= Future<
Response?> ? Function(Request request) -
NextHandler
= Future<
Response> Function(Request request, NextFunction next) - OnProgress = void Function(int bytesUploaded, int totalBytes)
- VoidFunction = void Function()
Exceptions / Errors
- ApiError
- Base class for exceptions thrown from the http_api package.
- ApiException
- Base class for exceptions thrown from the http_api package.
- RequestException