Package com._1c.g5.v8.dt.lifecycle
Interface IServicesOrchestrator
- All Known Implementing Classes:
ServicesOrchestrator
public interface IServicesOrchestrator
The services orchestrator.
It provides synchronized, ordered and solid way to manipulate the life cycle of the services.
All the methods are thread-safe.
- Since:
- 1.0.0
- See Also:
-
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
.
-
Method Details
-
startServices
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
.If the specified context is already started it does nothing.
- Parameters:
context
- the context the services are being start with, cannot benull
.progressMonitor
- the progress monitor, can benull
.- Since:
- 3.0.0
-
stopServices
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
.If the specified context is already stopped it does nothing.
- Parameters:
context
- the context the services are being stopped with, cannot benull
.progressMonitor
- the progress monitor, can benull
.- Since:
- 3.0.0
-
addListener
Adds aIServiceContextLifecycleListener
. The added listener will be notified about lifecycle changes for each supported service context.- Parameters:
listener
- the listener to add, cannot benull
.- Throws:
IllegalArgumentException
- if thelistener
isnull
.
-
removeListener
Removes a previously registered listener. In order to support removal, the listener implementation should implementObject#equals(Object)
andObject#hashCode()
to compare listener instances.- Parameters:
listener
- the listener to remove, cannot benull
.
-
isInfrastructureReady
boolean isInfrastructureReady()Checks if is infrastructure ready. In other words, checks if linking phase is performed.- Returns:
true
if the infrastructure is ready,false
- otherwise.- Since:
- 3.0.0
-