Package ghidra.util.datastruct
Class PrivatelyQueuedListener<P>
java.lang.Object
ghidra.util.datastruct.PrivatelyQueuedListener<P>
- Type Parameters:
P- the type of listener
A listener which queues invocations onto a separate executor
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPrivatelyQueuedListener(Class<P> iface, String threadNamePattern, P out) Create a new single-threaded privately-queued listenerPrivatelyQueuedListener(Class<P> iface, Executor executor, P out) Create a new privately-queued listener which will invoke the given "output" listener -
Method Summary
-
Field Details
-
in
The "input" listener, which should be added as a listener on other things -
executor
-
out
-
-
Constructor Details
-
PrivatelyQueuedListener
Create a new privately-queued listener which will invoke the given "output" listenerInvoking the listener methods of
inwill cause that invocation to be queued and eventually delivered to the given output listener. Note, as a result, it is assumed all listener methods return typevoid, since returning a value would require waiting on the invocation to complete, which defeats the purpose of the private queue. The invocations oninwill always returnnull, which will cause an exception if the return type is a different primitive.- Parameters:
iface- the interface of the listenerexecutor- the executor representing the processing queueout- the listener to receive the queued invocations
-
PrivatelyQueuedListener
Create a new single-threaded privately-queued listener- Parameters:
iface- the interface of the listenerthreadNamePattern- a pattern for naming the single threadout- the listener to receive the queued invocations
-
-
Method Details
-
setErrorHandler
-