dio_flow library
A Dio client with extended functionality for handling API requests, caching, authentication, retry logic, and more.
Classes
- ApiClient
- ApiEndpointFactory
- Factory for creating API endpoints from strings.
- ApiEndpointInterface
- Interface for API endpoints.
- CacheOptions
- DioFlowConfig
- Configuration for the dio_flow package.
- DioRefreshTokenRequestHandle
- for refreshToken Handle
- DioRequestHandler
- EndpointProvider
- Provider for managing API endpoints in the application.
- FailedResponseModel
- Concrete implementation of ResponseModel for failed API responses.
- FileHandler
- Handler for file upload and download operations using DioFlow.
- FileProgress
- Information about file upload/download progress.
- GraphQLHandler
- Handler for GraphQL operations using DioFlow.
- GraphQLOperation
- Represents a single GraphQL operation for batch requests.
- GraphQLQueryBuilder
- Utility class for building GraphQL queries programmatically.
- HttpMethods
- Utility class containing constants for HTTP methods.
- JsonUtils
- Utility class for common JSON operations.
- LinkModel
- Model representing a pagination link in API responses.
- LinksModel
- MetaModel
- MockDioFlow
- Mock implementation for DioFlow to support testing without real HTTP calls.
- MockResponse
- Represents a mock HTTP response for testing purposes.
- NetworkChecker
- Utility class for checking network connectivity.
-
PaginatedResult<
T> - A class that holds paginated results.
- PaginationHelper
- A helper class that provides utilities for working with paginated API endpoints.
- PaginationMeta
- A class that holds pagination metadata.
- PaginationUtils
- Utility class for common pagination operations.
- RefreshTokenResponse
- RequestOptionsModel
- Model class for configuring request options.
- ResponseModel
- Abstract class representing a standardized API response in the application.
- RetryOptions
- Configuration options for request retries.
- SuccessResponseModel
- Concrete implementation of ResponseModel for successful API responses.
- TokenManager
Enums
- ErrorType
- Enum representing specific types of errors that can occur in API requests.
Extensions
- JsonListExtensions on List
- Extension methods for List to simplify working with JSON data.
-
JsonMapExtensions
on Map<
String, dynamic> -
Extension methods for
Map<String, dynamic>to simplify JSON operations. - JsonStringExtensions on String
- Extension methods for String to simplify JSON parsing.
- ResponseModelExtension on ResponseModel
- Extension to add convenience methods to ResponseModel
Functions
-
removeAfterThirdSlash(
String url) → String
Typedefs
- ProgressCallback = void Function(int sent, int total)
- Callback function for tracking upload/download progress.
-
RefreshTokenHandler
= Future<
RefreshTokenResponse> Function(String refreshToken)