Class ServicesOrchestrator

java.lang.Object
com._1c.g5.v8.dt.internal.lifecycle.ServicesOrchestrator
All Implemented Interfaces:
IServicesOrchestrator

public final class ServicesOrchestrator extends Object implements IServicesOrchestrator
The implementation of IServicesOrchestrator.
  • Constructor Details

    • ServicesOrchestrator

      public ServicesOrchestrator(ILifecycleRegistry registry)
      Creates a new orchestrator.
      Parameters:
      registry - the lifecycle registry, cannot be [null.
      Throws:
      IllegalArgumentException - if the registry is null.
  • 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, see LifecyclePhase.

      If the specified context is already started it does nothing.

      Specified by:
      startServices in interface IServicesOrchestrator
      Parameters:
      context - the context the services are being start with, cannot be null.
      progressMonitor - the progress monitor, can be null.
    • 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, see LifecyclePhase.

      If the specified context is already stopped it does nothing.

      Specified by:
      stopServices in interface IServicesOrchestrator
      Parameters:
      context - the context the services are being stopped with, cannot be null.
      progressMonitor - the progress monitor, can be null.
    • addListener

      public void addListener(IServiceContextLifecycleListener listener)
      Description copied from interface: IServicesOrchestrator
      Adds a IServiceContextLifecycleListener. The added listener will be notified about lifecycle changes for each supported service context.
      Specified by:
      addListener in interface IServicesOrchestrator
      Parameters:
      listener - the listener to add, cannot be null.
    • removeListener

      public void removeListener(IServiceContextLifecycleListener listener)
      Description copied from interface: IServicesOrchestrator
      Removes a previously registered listener. In order to support removal, the listener implementation should implement Object#equals(Object) and Object#hashCode() to compare listener instances.
      Specified by:
      removeListener in interface IServicesOrchestrator
      Parameters:
      listener - the listener to remove, cannot be null.
    • 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 interface IServicesOrchestrator
      Returns:
      true if the infrastructure is ready, false - otherwise.