takeResponseBodyForInterceptionAsStream method

Future<StreamHandle> takeResponseBodyForInterceptionAsStream(
  1. InterceptionId interceptionId
)

Returns a handle to the stream representing the response body. Note that after this command, the intercepted request can't be continued as is -- you either need to cancel it or to provide the response body. The stream only supports sequential read, IO.read will fail if the position is specified.

Implementation

Future<io.StreamHandle> takeResponseBodyForInterceptionAsStream(
    InterceptionId interceptionId) async {
  var result =
      await _client.send('Network.takeResponseBodyForInterceptionAsStream', {
    'interceptionId': interceptionId,
  });
  return io.StreamHandle.fromJson(result['stream'] as String);
}