ASWImplementation class

Implemented types

Constructors

ASWImplementation.new({required Dio dio, List<Interceptor>? interceptors, Future<Either<String, ASWTokenPair>> tokenRefreshCallback(String refreshToken)?, VoidCallback? onTokenExpired})

Properties

currentTokens Future<ASWTokenPair?>
no setteroverride
dio → Dio
final
hashCode int
The hash code for this object.
no setterinherited
interceptors List<Interceptor>?
final
isAuthenticated Future<bool>
no setteroverride
isTokenExpired Future<bool>
no setteroverride
onTokenExpired VoidCallback?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
tokenRefreshCallback Future<Either<String, ASWTokenPair>> Function(String refreshToken)?
final

Methods

clearTokens() Future<void>
override
deleteMethod<T>(String endpoint, {ASWOption? option = const ASWOption(), dynamic body, CancelToken? cancelToken}) Future<Either<DioException, Response<T>>>
override
getMethod<T>(String endpoint, {ASWOption? option = const ASWOption(), CancelToken? cancelToken}) Future<Either<DioException, Response<T>>>
override
initialize() Future<void>
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
patchMethod<T>(String endpoint, {ASWOption? option = const ASWOption(), dynamic body, CancelToken? cancelToken}) Future<Either<DioException, Response<T>>>
override
postMethod<T>(String endpoint, {ASWOption? option = const ASWOption(), dynamic body, CancelToken? cancelToken}) Future<Either<DioException, Response<T>>>
override
putMethod<T>(String endpoint, {ASWOption? option = const ASWOption(), dynamic body, CancelToken? cancelToken}) Future<Either<DioException, Response<T>>>
override
setTokens(ASWTokenPair tokenPair) Future<void>
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited