streamResponse<R extends ARequest> method

void streamResponse<R extends ARequest>(
  1. R request,
  2. Duration interVal,
  3. ResponseProvider<R, F, S> responseProvider
)

Implementation

void streamResponse<R extends ARequest>(R request, Duration interVal,
    final ResponseProvider<R, F, S> responseProvider) async {
  output.present(await responseProvider(request));
  Timer.periodic(interVal, (timer) async {
    output.present(await responseProvider(request));
  });
}