addToken abstract method Null safety

FutureOr addToken(
  1. AuthServer server,
  2. AuthToken token,
  3. {AuthCode? issuedFrom}
)

Must store token.

token must be stored such that it is accessible from getToken, and until it is either revoked via removeToken or removeTokens, or until it has expired and can reasonably be believed to no longer be in use.

You may alter token prior to storing it. This may include replacing AuthToken.accessToken with another token format. The default token format will be a random 32 character string.

If this token was granted through an authorization code, issuedFrom is that code. Otherwise, issuedFrom is null.

Implementation

FutureOr addToken(AuthServer server, AuthToken token, {AuthCode? issuedFrom});