2020-01-12 10:30:05 +00:00
|
|
|
class OpenIdCredentials {
|
|
|
|
String accessToken;
|
|
|
|
String tokenType;
|
|
|
|
String matrixServerName;
|
2020-02-03 09:45:33 +00:00
|
|
|
num expiresIn;
|
2020-01-12 10:30:05 +00:00
|
|
|
|
|
|
|
OpenIdCredentials(
|
|
|
|
{this.accessToken,
|
|
|
|
this.tokenType,
|
|
|
|
this.matrixServerName,
|
|
|
|
this.expiresIn});
|
|
|
|
|
|
|
|
OpenIdCredentials.fromJson(Map<String, dynamic> json) {
|
|
|
|
accessToken = json['access_token'];
|
|
|
|
tokenType = json['token_type'];
|
|
|
|
matrixServerName = json['matrix_server_name'];
|
|
|
|
expiresIn = json['expires_in'];
|
|
|
|
}
|
2020-02-03 09:45:33 +00:00
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
2020-03-30 09:08:38 +00:00
|
|
|
var map = <String, dynamic>{};
|
|
|
|
final data = map;
|
|
|
|
data['access_token'] = accessToken;
|
|
|
|
data['token_type'] = tokenType;
|
|
|
|
data['matrix_server_name'] = matrixServerName;
|
|
|
|
data['expires_in'] = expiresIn;
|
2020-02-03 09:45:33 +00:00
|
|
|
return data;
|
|
|
|
}
|
2020-01-12 10:30:05 +00:00
|
|
|
}
|