fromJson static method
Implementation
static OnRampProvider? fromJson(Map<String, dynamic>? json) {
if (json == null) {
return null;
}
return OnRampProvider(
id: (json['id'] as String?) ?? '',
name: (json['name'] as String?) ?? '',
cryptocurrencies: List<String>.from(
((json['cryptocurrencies'] as List<dynamic>?) ?? <dynamic>[])
.map((item) => item as String)
.toList()),
supportsBaseCurrencies:
(json['supports_base_currencies'] as bool?) ?? false,
supportsLimits: (json['supports_limits'] as bool?) ?? false,
supportsQuote: (json['supports_quote'] as bool?) ?? false,
);
}