Class BlockableChannel
Package
Multi-producer-multi-consumer (MPMC) channel.
This is a channel that can be used to send data between threads. It is thread safe and can be used by multiple threads at the same time.
Additionally, the channel can be put into a blocking mode, which will cause all calls to Receive to block until the channel is unblocked.
Inner Types
Public Methods
AddReceiver
()
Public
Close
()
All calls to Receive and ReceiveNoBlock will now return PopState.Closed.
Public
Push
(path)
Push a path to the end of the queue.
Public
PushFront
(path)
Push a path to the front of the queue.
Public
Reopen
()
Resets a closed channel so that it can be used again.
Public
Public Variables
allReceiversBlocked
True if blocking and all receivers are waiting for unblocking.
Public
isBlocked
If true, all calls to Receive will block until this property is set to false.
Public
isEmpty
True if the queue is empty.
Public
numReceivers
Public
Private/Protected Members
blocked
Private
lockObj
Private
Readonly
queue
Private
starving
Private
waitingReceivers
Private