recv method
Attempts to wait for a value on this receiver, returning Err
of:
RecvError$Disconnected if the Sender called close and the buffer is empty.
RecvError$Other if the item in the buffer is an error, indicated by the sender calling addError
.
Implementation
@override
Future<Result<T, RecvError>> recv() async {
try {
return await _next();
} catch (error) {
return Err(RecvError$Other(error));
}
}