T
- Type of items contained in the queue to be consumedPoller.consumeQueue(java.util.Queue, java.util.function.Consumer)
or
BlockingQueueConsumer
for replacement@Deprecated public class BlockingQueueConsumer<T> extends BlockingQueueConsumer<T>
BlockingQueueConsumer
. This class
slipped under the radar, causing the implementation and interface to be significantly behind in
threadly 5.X. Please switch to
Poller.consumeQueue(java.util.Queue, java.util.function.Consumer)
or
BlockingQueueConsumer
.Modifier and Type | Class and Description |
---|---|
static interface |
BlockingQueueConsumer.ConsumerAcceptor<T>
Deprecated.
Interface for an implementation which can accept consumed tasks.
|
Constructor and Description |
---|
BlockingQueueConsumer(java.util.concurrent.ThreadFactory threadFactory,
java.util.concurrent.BlockingQueue<? extends T> queue,
BlockingQueueConsumer.ConsumerAcceptor<? super T> acceptor)
Deprecated.
Constructs a new consumer, with a provided queue to consume from, and an acceptor to accept
items.
|
BlockingQueueConsumer(java.util.concurrent.ThreadFactory threadFactory,
java.lang.String threadName,
java.util.concurrent.BlockingQueue<? extends T> queue,
BlockingQueueConsumer.ConsumerAcceptor<? super T> acceptor)
Deprecated.
Constructs a new consumer, with a provided queue to consume from, and an acceptor to accept
items.
|
makeForHandlers
hasStopped, isRunning, start, startIfNotStarted, stop, stopIfRunning
public BlockingQueueConsumer(java.util.concurrent.ThreadFactory threadFactory, java.util.concurrent.BlockingQueue<? extends T> queue, BlockingQueueConsumer.ConsumerAcceptor<? super T> acceptor)
threadFactory
- ThreadFactory to construct new thread for consumer to run onqueue
- queue to consume fromacceptor
- acceptor to provide consumed items topublic BlockingQueueConsumer(java.util.concurrent.ThreadFactory threadFactory, java.lang.String threadName, java.util.concurrent.BlockingQueue<? extends T> queue, BlockingQueueConsumer.ConsumerAcceptor<? super T> acceptor)
threadFactory
- ThreadFactory to construct new thread for consumer to run onthreadName
- Name of thread consumer runs on, or null
to generate a default onequeue
- queue to consume fromacceptor
- acceptor to provide consumed items to