示例#1
0
 public QueueConsumer(IFiber target, Action <TMsg> callback, QueueChannel3 <TMsg> eventChannel)
 {
     _target       = target;
     _callback     = callback;
     _eventChannel = eventChannel;
     _cache        = ConsumeNext;
 }
示例#2
0
 public AsyncQueueConsumer(IAsyncFiber target, Func <TMsg, Task> callback,
                           QueueChannel3 <TMsg> eventChannel)
 {
     _target       = target;
     _callback     = callback;
     _eventChannel = eventChannel;
     _cache        = ConsumeNext;
 }