write method
Implementation
void write(MessageStreamChunk chunk) async {
if (closed) {
throw RoomServerException("cannot write a closed MessageStream");
}
await _client.sendMessage(
to: to,
type: "stream.chunk",
message: {"stream_id": _streamId, "header": chunk.header},
attachment: chunk.data,
);
}