onResonse method

  1. @override
TronChainParameters onResonse(
  1. Map<String, dynamic> result
)
override

Converts the response result to the specified type RESULT.

Implementation

@override
TronChainParameters onResonse(result) {
  final List<Map<String, dynamic>> chainParams =
      List.from(result["chainParameter"]);
  final Map<String, dynamic> params = {
    for (final i in chainParams) i["key"]: i["value"]
  };
  return TronChainParameters.fromJson(params);
}