Module channel

Source
Expand description

An MPSC channel whose receiving end is an event source

Create a channel using channel(), which returns a Sender that can be cloned and sent accross threads if T: Send, and a Channel that can be inserted into an EventLoop. It will generate one event per message.

A synchronous version of the channel is provided by sync_channel, in which the SyncSender will block when the channel is full.

Structs§

Channel
The receiving end of the channel
ChannelError
An error arising from processing events for a channel.
Sender
The sender end of a channel
SyncSender
The sender end of a synchronous channel

Enums§

Event
The events generated by the channel event source

Functions§

channel
Create a new asynchronous channel
sync_channel
Create a new synchronous, bounded channel