Skip to content

Commit 18585de

Browse files
committed
Implement GetChannel(for Selecting channels usages)
1 parent 39531ae commit 18585de

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

queue.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -643,8 +643,15 @@ func (q *BufferedChannelQueue) GetFreeNodeHookPoolIntervalDuration() time.Durati
643643
return q.freeNodeHookPoolIntervalDuration
644644
}
645645

646+
// GetChannel Get Channel(for Selecting channels usages)
647+
func (q *BufferedChannelQueue) GetChannel() chan interface{} {
648+
q.notifyWorkers()
649+
650+
return q.blockingQueue
651+
}
652+
646653
// Count Count items
647-
func (q *BufferedChannelQueue[T]) Count() int {
654+
func (q *BufferedChannelQueue) Count() int {
648655
if q.isClosed.Get() {
649656
return 0
650657
}

0 commit comments

Comments
 (0)