Esempio n. 1
0
        /// <summary>
        /// Store the given <see cref="T:Quartz.ICalendar"/>.
        /// </summary>
        /// <param name="name">The name.</param><param name="calendar">The <see cref="T:Quartz.ICalendar"/> to be stored.</param><param name="replaceExisting">If <see langword="true"/>, any <see cref="T:Quartz.ICalendar"/> existing
        ///             in the <see cref="T:Quartz.Spi.IJobStore"/> with the same name and group
        ///             should be over-written.</param><param name="updateTriggers">If <see langword="true"/>, any <see cref="T:Quartz.ITrigger"/>s existing
        ///             in the <see cref="T:Quartz.Spi.IJobStore"/> that reference an existing
        ///             Calendar with the same name with have their next fire time
        ///             re-computed with the new <see cref="T:Quartz.ICalendar"/>.</param><throws>ObjectAlreadyExistsException </throws>
        public Task StoreCalendar(string name, ICalendar calendar, bool replaceExisting, bool updateTriggers, CancellationToken cancellationToken = default(CancellationToken))
        {
            _logger.Info("StoreCalendar");
            DoWithLock(() => _storage.StoreCalendar(name, calendar, replaceExisting, updateTriggers),
                       string.Format("Error on store calendar - {0}", name));

            return(Task.FromResult(0));
        }
Esempio n. 2
0
 /// <summary>
 /// Store the given <see cref="T:Quartz.ICalendar"/>.
 /// </summary>
 /// <param name="name">The name.</param><param name="calendar">The <see cref="T:Quartz.ICalendar"/> to be stored.</param><param name="replaceExisting">If <see langword="true"/>, any <see cref="T:Quartz.ICalendar"/> existing
 ///             in the <see cref="T:Quartz.Spi.IJobStore"/> with the same name and group
 ///             should be over-written.</param><param name="updateTriggers">If <see langword="true"/>, any <see cref="T:Quartz.ITrigger"/>s existing
 ///             in the <see cref="T:Quartz.Spi.IJobStore"/> that reference an existing
 ///             Calendar with the same name with have their next fire time
 ///             re-computed with the new <see cref="T:Quartz.ICalendar"/>.</param><throws>ObjectAlreadyExistsException </throws>
 public void StoreCalendar(string name, ICalendar calendar, bool replaceExisting, bool updateTriggers)
 {
     _logger.Info("StoreCalendar");
     DoWithLock(() => _storage.StoreCalendar(name, calendar, replaceExisting, updateTriggers),
                string.Format("Error on store calendar - {0}", name));
 }