public class BlockingEventLoop extends AbstractLifecycleEventLoop implements net.openhft.chronicle.core.threads.EventLoop
name| Constructor and Description |
|---|
BlockingEventLoop(@NotNull net.openhft.chronicle.core.threads.EventLoop parent,
@NotNull String name,
@NotNull Supplier<Pauser> pauser) |
BlockingEventLoop(@NotNull String name) |
| Modifier and Type | Method and Description |
|---|---|
void |
addHandler(@NotNull net.openhft.chronicle.core.threads.EventHandler handler)
This can be called multiple times and each handler will be executed in its own thread
|
boolean |
isAlive() |
protected void |
performClose() |
protected void |
performStart()
Implement whatever this event loop needs to start, will only
ever be called once
|
protected void |
performStopFromNew()
Implement a stop from
EventLoopLifecycle.NEW state, should block until all
handlers have had EventHandler.loopFinished() called. |
protected void |
performStopFromStarted()
Implement a stop from
EventLoopLifecycle.STARTED state, should block until all
handlers have completed their final iteration and had
EventHandler.loopFinished() called. |
String |
toString() |
void |
unpause() |
awaitTermination, isStarted, isStopped, name, nameWithSlash, start, stopassertCloseable, assertCloseablesClosed, close, createdHere, disableCloseableTracing, enableCloseableTracing, gcAndWaitForCloseablesToClose, isClosed, isClosing, isInUserThread, referenceId, shouldPerformCloseInBackground, shouldWaitForClosed, singleThreadedCheckDisabled, singleThreadedCheckDisabled, singleThreadedCheckReset, threadSafetyCheck, throwExceptionIfClosed, throwExceptionIfClosedInSetter, unmonitor, unmonitor, waitForCloseablesToClose, waitForClosed, warnAndCloseIfNotClosedclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitclose, inEventLoop, isStopped, name, runsInsideCoreLoop, start, stoppublic BlockingEventLoop(@NotNull
@NotNull net.openhft.chronicle.core.threads.EventLoop parent,
@NotNull
@NotNull String name,
@NotNull
@NotNull Supplier<Pauser> pauser)
public BlockingEventLoop(@NotNull
@NotNull String name)
public void addHandler(@NotNull
@NotNull net.openhft.chronicle.core.threads.EventHandler handler)
addHandler in interface net.openhft.chronicle.core.threads.EventLoophandler - to executeprotected void performStart()
AbstractLifecycleEventLoopperformStart in class AbstractLifecycleEventLooppublic void unpause()
unpause in interface net.openhft.chronicle.core.threads.EventLoopprotected void performStopFromNew()
AbstractLifecycleEventLoopEventLoopLifecycle.NEW state, should block until all
handlers have had EventHandler.loopFinished() called.performStopFromNew in class AbstractLifecycleEventLoopprotected void performStopFromStarted()
AbstractLifecycleEventLoopEventLoopLifecycle.STARTED state, should block until all
handlers have completed their final iteration and had
EventHandler.loopFinished() called.performStopFromStarted in class AbstractLifecycleEventLooppublic boolean isAlive()
isAlive in interface net.openhft.chronicle.core.threads.EventLoopprotected void performClose()
performClose in class AbstractLifecycleEventLooppublic String toString()
toString in class net.openhft.chronicle.core.io.AbstractCloseableCopyright © 2024. All rights reserved.