Esempio n. 1
0
 public TestWorker(StudioXTimer timer, IMqMessagePublisher publisher)
     : base(timer)
 {
     this.publisher   = publisher;
     Timer.Period     = 3000;//3 seconds
     Timer.RunOnStart = true;
 }
Esempio n. 2
0
        /// <summary>
        ///     Initializes a new instance of the <see cref="BackgroundJobManager" /> class.
        /// </summary>
        public BackgroundJobManager(
            IIocResolver iocResolver,
            IBackgroundJobStore store,
            StudioXTimer timer)
            : base(timer)
        {
            this.store       = store;
            this.iocResolver = iocResolver;

            EventBus = NullEventBus.Instance;

            Timer.Period = JobPollPeriod;
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="PeriodicBackgroundWorkerBase"/> class.
 /// </summary>
 /// <param name="timer">A timer.</param>
 protected PeriodicBackgroundWorkerBase(StudioXTimer timer)
 {
     Timer          = timer;
     Timer.Elapsed += Timer_Elapsed;
 }