Package org.eclipse.aether.internal.impl
Class DefaultRepositorySystemLifecycle
- java.lang.Object
-
- org.eclipse.aether.internal.impl.DefaultRepositorySystemLifecycle
-
- All Implemented Interfaces:
RepositorySystemLifecycle
@Singleton @Named public class DefaultRepositorySystemLifecycle extends java.lang.Object implements RepositorySystemLifecycle
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.concurrent.CopyOnWriteArrayList<java.lang.Runnable>
onSystemEndedHandlers
private java.util.concurrent.atomic.AtomicBoolean
shutdown
-
Constructor Summary
Constructors Constructor Description DefaultRepositorySystemLifecycle()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addOnSystemEndedHandler(java.lang.Runnable handler)
Registers an "on repository system end" handler.private void
requireNotShutdown()
void
systemEnded()
Marks the repository system as ended (shut down): all "on close" handlers will be invoked.
-
-
-
Method Detail
-
systemEnded
public void systemEnded()
Description copied from interface:RepositorySystemLifecycle
Marks the repository system as ended (shut down): all "on close" handlers will be invoked. This method may be invoked multiple times, only once will execute, subsequent calls will be no-op.- Specified by:
systemEnded
in interfaceRepositorySystemLifecycle
-
addOnSystemEndedHandler
public void addOnSystemEndedHandler(java.lang.Runnable handler)
Description copied from interface:RepositorySystemLifecycle
Registers an "on repository system end" handler.Throws if repository system is already shut down.
- Specified by:
addOnSystemEndedHandler
in interfaceRepositorySystemLifecycle
-
requireNotShutdown
private void requireNotShutdown()
-
-