Documentation ¶
Overview ¶
Package pump provides an infinitely buffered event channel.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Pump ¶
type Pump struct {
// contains filtered or unexported fields
}
Pump is an event pump, such that calling Send(e) will eventually send e on the event channel, in order, but Send will always complete soon, even if nothing is receiving on the event channel. It is effectively an infinitely buffered channel.
In particular, goroutine A calling p.Send will not deadlock even if goroutine B that's responsible for receiving on p.Events() is currently blocked trying to send to A on a separate channel.
Click to show internal directories.
Click to hide internal directories.