Token to fetch session for
The {@link Session} associated with this token
Returns the {@link User} a {@link Session} belongs to based on its {@link Session#token}.
Token to fetch user for
The {@link User} associated with the session of this token
Initialises a {@link Session} for a {@link User}.
The {@link User} to initialise the session for
The newly initialised {@link Session}
Invalidates a {@link Session}.
The {@link Session} to terminate
Validates that a {@link Session#token}:
By supplying the refresh parameter, the session can be refreshed (i.e. a new token generated and the old one discarded) so the user does not ever have to re-login if they just keep logging in more often than the token lifetime.
Token to validate
Whether to refresh the session
Whether the session was valid, and if refresh is enabled, the new session to give to the user instead
Generated using TypeDoc
Returns the {@link Session} linked to a {@link Session#token}.