Session class

Constructors

Session({required String accessToken, int? expiresIn, String? refreshToken, required String tokenType, String? providerToken, String? providerRefreshToken, required User user})

Properties

accessToken String
final
expiresAt int?
A timestamp of when the token will expire. Returned when a login is confirmed.
getter/setter pair
expiresIn int?
The number of seconds until the token expires (since it was issued). Returned when a login is confirmed.
final
hashCode int
The hash code for this object.
no setteroverride
isExpired bool
Returns 'true` if the token is expired or will expire in the next 10 seconds.
no setter
providerRefreshToken String?
final
providerToken String?
final
refreshToken String?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
tokenType String
final
user User
final

Methods

copyWith({String? accessToken, int? expiresIn, String? refreshToken, String? tokenType, String? providerToken, String? providerRefreshToken, User? user}) Session
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
toString() String
A string representation of this object.
override

Operators

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

Static Methods

fromJson(Map<String, dynamic> json) Session?
Returns a Session object from a map of json returns null if there is no access_token present