AuthProvider class

The Authentication Provider grants the ability to authenticate to the anybill service.

Constructors

AuthProvider.test({required UserService userService, required TokenProvider tokenProvider, required UserStore userStore})
Test provider. Use only for test.

Properties

hashCode int
The hash code for this object.
read-onlyinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited

Methods

getCachedUserInformation() Future<AnybillResult<UserInformationDto>>
Retrieve the cached user information data from the database.
getCachedUserQrCode() Future<AnybillResult<UserQrCodeDto>>
Retrieve the cached user QR code data from the database.
getUserInformation({int requestCount = 2}) Future<AnybillResult<UserInformationDto>>
Retrieve an UserInformationDto from the current authenticated user.
getUserQrCode({int requestCount = 2}) Future<AnybillResult<UserQrCodeDto>>
Retrieve an UserQrCodeDto from the current authenticated user. Use this qr code data to display a qr code which can be scanned by the POS.
loginUserWithToken({required String? accessToken, required String? refreshToken, String? expiresIn, String? tokenType}) Future<AnybillResult<void>>
Login the user with the token information.
logoutUser({int requestCount = 2}) Future<AnybillResult<void>>
Logout the currently logged in user.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

instance AuthProvider
Provides an instance of the AuthProvider
final