Closes an Channel
.
Instances For
Receives a message, without blocking. The returned task waits for the message. Every message is only received once.
Returns none
if the channel is closed and the queue is empty.
Instances For
ch.forAsync f
calls f
for every messages received on ch
.
Note that if this function is called twice, each forAsync
only gets half the messages.
Receives all currently queued messages from the channel.
Those messages are dequeued and will not be returned by recv?
.
Instances For
Type tag for synchronous (blocking) operations on a Channel
.
Instances For
Synchronously receives a message from the channel.
Every message is only received once.
Returns none
if the channel is closed and the queue is empty.
Instances For
for msg in ch.sync do ...
receives all messages in the channel until it is closed.