Class ServicesOrchestrator
java.lang.Object
com._1c.g5.v8.dt.internal.lifecycle.ServicesOrchestrator
- All Implemented Interfaces:
IServicesOrchestrator
The implementation of
IServicesOrchestrator
.-
Constructor Summary
ConstructorsConstructorDescriptionServicesOrchestrator
(ILifecycleRegistry registry) Creates a new orchestrator. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addListener
(IServiceContextLifecycleListener listener) Adds aIServiceContextLifecycleListener
.boolean
Checks if is infrastructure ready.void
Removes a previously registered listener.void
startServices
(ILifecycleContext context, org.eclipse.core.runtime.IProgressMonitor progressMonitor) Starts the lifecycle services in accordance with lifecycle phases order and participants dependencies.
For more information about phases, seeLifecyclePhase
.void
stopServices
(ILifecycleContext context, org.eclipse.core.runtime.IProgressMonitor progressMonitor) Stops the lifecycle services in accordance with lifecycle phases order and participants dependencies.
For more information about phases, seeLifecyclePhase
.
-
Constructor Details
-
ServicesOrchestrator
Creates a new orchestrator.- Parameters:
registry
- the lifecycle registry, cannot be [null
.- Throws:
IllegalArgumentException
- if theregistry
isnull
.
-
-
Method Details
-
startServices
public void startServices(ILifecycleContext context, org.eclipse.core.runtime.IProgressMonitor progressMonitor) Description copied from interface:IServicesOrchestrator
Starts the lifecycle services in accordance with lifecycle phases order and participants dependencies.
For more information about phases, seeLifecyclePhase
.If the specified context is already started it does nothing.
- Specified by:
startServices
in interfaceIServicesOrchestrator
- Parameters:
context
- the context the services are being start with, cannot benull
.progressMonitor
- the progress monitor, can benull
.
-
stopServices
public void stopServices(ILifecycleContext context, org.eclipse.core.runtime.IProgressMonitor progressMonitor) Description copied from interface:IServicesOrchestrator
Stops the lifecycle services in accordance with lifecycle phases order and participants dependencies.
For more information about phases, seeLifecyclePhase
.If the specified context is already stopped it does nothing.
- Specified by:
stopServices
in interfaceIServicesOrchestrator
- Parameters:
context
- the context the services are being stopped with, cannot benull
.progressMonitor
- the progress monitor, can benull
.
-
addListener
Description copied from interface:IServicesOrchestrator
Adds aIServiceContextLifecycleListener
. The added listener will be notified about lifecycle changes for each supported service context.- Specified by:
addListener
in interfaceIServicesOrchestrator
- Parameters:
listener
- the listener to add, cannot benull
.
-
removeListener
Description copied from interface:IServicesOrchestrator
Removes a previously registered listener. In order to support removal, the listener implementation should implementObject#equals(Object)
andObject#hashCode()
to compare listener instances.- Specified by:
removeListener
in interfaceIServicesOrchestrator
- Parameters:
listener
- the listener to remove, cannot benull
.
-
isInfrastructureReady
public boolean isInfrastructureReady()Description copied from interface:IServicesOrchestrator
Checks if is infrastructure ready. In other words, checks if linking phase is performed.- Specified by:
isInfrastructureReady
in interfaceIServicesOrchestrator
- Returns:
true
if the infrastructure is ready,false
- otherwise.
-