parseHttpBasedResponse method

HttpBasedResponse parseHttpBasedResponse (
  1. String body
)

Implementation

HttpBasedResponse parseHttpBasedResponse(String body) {
  Map<String, dynamic> resContent = jsonDecode(body);
  logTrace('Server response decoded as JSON.');
  List<int> resBuffer =
      (resContent['proto'] as List<dynamic>).map((e) => e as int).toList();
  HttpBasedResponse response = HttpBasedResponse.fromBuffer(resBuffer);
  return response;
}