Module postage::barrier[][src]

Barriers transmit when the sender half is dropped, and can synchronize events in async tasks.

The barrier can also be triggered with tx.send(()).

Structs

Receiver

A barrier reciever. Can be used with the postage::Stream trait to return a () value when the Sender is dropped.

Sender

The sender half of a barrier channel. Dropping the sender transmits to the receiver.

Functions

channel

Constructs a pair of barrier endpoints, which transmits when the sender is dropped.