Documentation ¶
Overview ¶
Non-blocking channel for Go.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NonBlockingChan ¶
type NonBlockingChan struct { Send chan<- interface{} Recv <-chan interface{} // contains filtered or unexported fields }
Special type that mimics the behavior of a channel but does not block when items are sent. Items are stored internally until received. Closing the Send channel will cause the Recv channel to be closed after all items have been received.
func (*NonBlockingChan) Len ¶
func (n *NonBlockingChan) Len() int
Retrieve the number of items waiting to be received.
Click to show internal directories.
Click to hide internal directories.