createSessionManager method

SessionManager createSessionManager({
  1. required Duration timeout,
  2. bool clearTokensOnExpiry = true,
})

Creates an inactivity-based SessionManager wired to this kit's token storage, so tokens are wiped when the session times out.

The caller owns the returned manager and must dispose() it.

Implementation

SessionManager createSessionManager({
  required Duration timeout,
  bool clearTokensOnExpiry = true,
}) => SessionManager(
  timeout: timeout,
  tokenStorage: tokenStorage,
  tokenExpiry: tokenExpiry,
  clearTokensOnExpiry: clearTokensOnExpiry,
);