Esempio n. 1
0
        /// <summary>
        /// Add an <see cref="IJobHandlerLocator"/> for loading handlers
        /// </summary>
        /// <param name="locator">Locator to add</param>
        public void AddHandlerLocator(IJobHandlerLocator locator)
        {
            if (locator == null)
            {
                throw new ArgumentNullException(nameof(locator));
            }

            _handlerLocator.AddLocator(locator);

            foreach (var handler in locator.GetHandlers())
            {
                AddHandler(handler, false);
            }
        }
Esempio n. 2
0
 public void AddLocator(IJobHandlerLocator locator)
 {
     _locators.Add(locator);
 }
 public BackgroundJobSpawner(IThreadManager threadManager, IJobHandlerLocator jobHandlerLocator)
 {
     _threadManager = threadManager;
       _jobHandlerLocator = jobHandlerLocator;
 }