fromJson static method

UserResponse fromJson(
  1. dynamic value
)

Returns a new UserResponse instance and imports

Implementation

// ignore: prefer_constructors_over_static_methods
static UserResponse fromJson(dynamic value) {
  final json = value.cast<String, dynamic>();
  return UserResponse(
    id: mapValueOfType<String>(json, r'id'),
    oauthID: mapValueOfType<String>(json, r'oauthID'),
    name: mapValueOfType<String>(json, r'name'),
    status: UserResponseStatusEnum.fromJson(json[r'status']),
    links: json[r'links'] == null
        ? null
        : UserResponseLinks.fromJson(json[r'links']),
  );
}