public final class ShutdownManager extends Object implements org.forgerock.util.thread.listener.ShutdownManager
| Modifier and Type | Field and Description |
|---|---|
protected Set<org.forgerock.util.thread.listener.ShutdownListener>[] |
listeners |
protected boolean |
shutdownCalled |
| Modifier and Type | Method and Description |
|---|---|
void |
addApplicationSSOTokenDestroyer(org.forgerock.util.thread.listener.ShutdownListener listener)
Adds application single-sign-on token destroyer.
|
void |
addShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener)
Adds a ShutdownListener to this ShutdownManager.
|
void |
addShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener,
org.forgerock.util.thread.listener.ShutdownPriority priority)
Adds a ShutdownListener to this ShutdownManager with indicated level.
|
static ShutdownManager |
getInstance()
Returns the static instance of ShutdownManager in the VM.
|
void |
removeShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener)
Removes a ShutdownListener from this ShutdownManager.
|
void |
replaceShutdownListener(org.forgerock.util.thread.listener.ShutdownListener oldListener,
org.forgerock.util.thread.listener.ShutdownListener newListener,
org.forgerock.util.thread.listener.ShutdownPriority priority)
Replaces an existing ShutdownListener with the new ShutdownListener.
|
void |
shutdown()
Shuts down all the listeners in this ShutdownManager.
|
protected Set<org.forgerock.util.thread.listener.ShutdownListener>[] listeners
protected volatile boolean shutdownCalled
public static ShutdownManager getInstance()
public void addShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener)
throws IllegalMonitorStateException
addShutdownListener in interface org.forgerock.util.thread.listener.ShutdownManagerlistener - The listener to be addedIllegalMonitorStateExceptionpublic void addShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener,
org.forgerock.util.thread.listener.ShutdownPriority priority)
throws IllegalMonitorStateException
addShutdownListener in interface org.forgerock.util.thread.listener.ShutdownManagerlistener - The listener to be addedpriority - The priority to shutdown for the shutdown listenerIllegalMonitorStateExceptionpublic void replaceShutdownListener(org.forgerock.util.thread.listener.ShutdownListener oldListener,
org.forgerock.util.thread.listener.ShutdownListener newListener,
org.forgerock.util.thread.listener.ShutdownPriority priority)
replaceShutdownListener in interface org.forgerock.util.thread.listener.ShutdownManageroldListener - To be replaced.newListener - The replacement.priority - Replacement listeners priority. If null default addShutdownListener method will be used.public void removeShutdownListener(org.forgerock.util.thread.listener.ShutdownListener listener)
throws IllegalMonitorStateException
removeShutdownListener in interface org.forgerock.util.thread.listener.ShutdownManagerlistener - The listener to be removedIllegalMonitorStateExceptionpublic void shutdown()
throws IllegalMonitorStateException
shutdown in interface org.forgerock.util.thread.listener.ShutdownManagerIllegalMonitorStateExceptionpublic void addApplicationSSOTokenDestroyer(org.forgerock.util.thread.listener.ShutdownListener listener)
listener - Listener object.Copyright © 2010–2023 Open Identity Platform Community. All rights reserved.