public class SafeMessageQueue extends java.lang.Object implements MessageQueue
| Modifier and Type | Field and Description |
|---|---|
java.lang.String |
logTag |
| Constructor and Description |
|---|
SafeMessageQueue(Timer timer,
MessageFactory factory,
java.lang.String logTag) |
| Modifier and Type | Method and Description |
|---|---|
void |
cancelMessages(MessagePredicate predicate) |
void |
clear() |
void |
consume(MessageQueueConsumer consumer) |
boolean |
isRunning() |
void |
post(Message message) |
void |
postAt(Message message,
long readyNs) |
void |
postAtFront(Message message) |
protected void |
removeMessages(MessagePredicate predicate) |
void |
stop() |
public SafeMessageQueue(Timer timer, MessageFactory factory, java.lang.String logTag)
public boolean isRunning()
public void consume(MessageQueueConsumer consumer)
consume in interface MessageQueuepublic void stop()
stop in interface MessageQueuepublic void clear()
clear in interface MessageQueuepublic void post(Message message)
post in interface MessageQueuepublic void postAt(Message message, long readyNs)
postAt in interface MessageQueuepublic void cancelMessages(MessagePredicate predicate)
cancelMessages in interface MessageQueuepublic void postAtFront(Message message)
protected void removeMessages(MessagePredicate predicate)