C# Class Fibrous.Queues.BoundedQueue

Queue with bounded capacity. Will throw exception if capacity does not recede prior to wait time. Good for putting back pressure on fast publishers
Inheritance: IQueue
Mostrar archivo Open project: chrisa23/Fibrous

Public Methods

Method Description
BoundedQueue ( int depth, int maxWaitTime = Int32.MaxValue ) : System
Dispose ( ) : void
Drain ( ) : List
Enqueue ( System.Action action ) : void

Enqueue action.

Private Methods

Method Description
ReadyToDequeue ( ) : bool
SpaceAvailable ( int toAdd ) : bool

Method Details

BoundedQueue() public method

public BoundedQueue ( int depth, int maxWaitTime = Int32.MaxValue ) : System
depth int
maxWaitTime int
return System

Dispose() public method

public Dispose ( ) : void
return void

Drain() public method

public Drain ( ) : List
return List

Enqueue() public method

Enqueue action.
public Enqueue ( System.Action action ) : void
action System.Action
return void