Пример #1
0
 /// <summary>
 /// Remove (delete) the <see cref="T:Quartz.ITrigger"/> with the given key.
 /// </summary>
 /// <remarks>
 /// <para>
 /// If removal of the <see cref="T:Quartz.ITrigger"/> results in an empty group, the
 ///             group should be removed from the <see cref="T:Quartz.Spi.IJobStore"/>'s list of
 ///             known group names.
 /// </para>
 /// <para>
 /// If removal of the <see cref="T:Quartz.ITrigger"/> results in an 'orphaned' <see cref="T:Quartz.IJob"/>
 ///             that is not 'durable', then the <see cref="T:Quartz.IJob"/> should be deleted
 ///             also.
 /// </para>
 /// </remarks>
 /// <returns>
 /// <see langword="true"/> if a <see cref="T:Quartz.ITrigger"/> with the given
 ///             name and group was found and removed from the store.
 /// </returns>
 public Task <bool> RemoveTrigger(TriggerKey triggerKey, CancellationToken cancellationToken = default(CancellationToken))
 {
     _logger.Info("RemoveTrigger");
     return(Task.FromResult(DoWithLock(() => _storage.RemoveTrigger(triggerKey),
                                       "Could not remove trigger")));
 }
Пример #2
0
 /// <summary>
 /// Remove (delete) the <see cref="T:Quartz.ITrigger"/> with the given key.
 /// </summary>
 /// <remarks>
 /// <para>
 /// If removal of the <see cref="T:Quartz.ITrigger"/> results in an empty group, the
 ///             group should be removed from the <see cref="T:Quartz.Spi.IJobStore"/>'s list of
 ///             known group names.
 /// </para>
 /// <para>
 /// If removal of the <see cref="T:Quartz.ITrigger"/> results in an 'orphaned' <see cref="T:Quartz.IJob"/>
 ///             that is not 'durable', then the <see cref="T:Quartz.IJob"/> should be deleted
 ///             also.
 /// </para>
 /// </remarks>
 /// <returns>
 /// <see langword="true"/> if a <see cref="T:Quartz.ITrigger"/> with the given
 ///             name and group was found and removed from the store.
 /// </returns>
 public bool RemoveTrigger(TriggerKey triggerKey)
 {
     _logger.Info("RemoveTrigger");
     return(DoWithLock(() => _storage.RemoveTrigger(triggerKey),
                       "Could not remove trigger"));
 }