getContent method
Returns content of the response body.
returns
A function that receives the response body when the request
completes.
Implementation
Future<GetContentResult> getContent() {
var $completer = Completer<GetContentResult>();
_wrapped.getContent((
String content,
String encoding,
) {
if (checkRuntimeLastError($completer)) {
$completer.complete(GetContentResult(
content: content,
encoding: encoding,
));
}
}.toJS);
return $completer.future;
}