示例#1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ProcessManagerCoordinator" /> class.
        /// </summary>
        /// <param name="eventBus">The event bus.</param>
        /// <param name="commandDispatcher">The command dispatcher.</param>
        /// <param name="processManagerFinderRepository">The process manager finder repository.</param>
        /// <param name="dependencyService">The dependency service.</param>
        public ProcessManagerCoordinator(
            IEventBus eventBus,
            ICommandDispatcher commandDispatcher,
            IProcessManagerFinderRepository processManagerFinderRepository,
            IDependencyService dependencyService)
        {
            _processManagerFinderRepository = processManagerFinderRepository;
            _dependencyService = dependencyService;

            //Register for events and commands
            eventBus.Subscribe(this);
            commandDispatcher.Subscribe(this);
        }
示例#2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ProcessManagerCoordinator" /> class.
        /// </summary>
        /// <param name="eventBus">The event bus.</param>
        /// <param name="commandDispatcher">The command dispatcher.</param>
        /// <param name="processManagerFinderRepository">The process manager finder repository.</param>
        /// <param name="processManagers">The process managers.</param>
        public ProcessManagerCoordinator(
            IEventBus eventBus,
            ICommandDispatcher commandDispatcher,
            IProcessManagerFinderRepository processManagerFinderRepository,
            IEnumerable <IProcessManager> processManagers)
        {
            _processManagerFinderRepository = processManagerFinderRepository;
            _processManagers = processManagers;

            //Register for events and commands
            eventBus.Subscribe(this);
            commandDispatcher.Subscribe(this);
        }