FlushCallback typedef
A flush/drain callback (CORELIB_PLAN ยง5.1). Receives a view of the newly filled bytes; the encoder reuses its buffer immediately afterwards, so a callback that keeps the data must copy it. The view is only valid for the duration of the call.
Implementation
typedef FlushCallback = void Function(Uint8List chunk);