Example #1
0
        /// <summary>
        /// StoreJob and its related Triggers
        /// </summary>
        /// <param name="job">IJobDetail</param>
        /// <param name="triggers">Triggers</param>
        protected void StoreJobAndTriggers(IJobDetail job, global::Quartz.Collection.ISet <ITrigger> triggers)
        {
            var dictionary = new Dictionary <IJobDetail, global::Quartz.Collection.ISet <ITrigger> > {
                { job, triggers }
            };

            JobStore.StoreJobsAndTriggers(dictionary, true);
        }
Example #2
0
        /// <summary>
        /// StoreJob and its related Triggers
        /// </summary>
        /// <param name="job">IJobDetail</param>
        /// <param name="triggers">Triggers</param>
        protected void StoreJobAndTriggers(IJobDetail job, ISet <ITrigger> triggers)
        {
            Dictionary <IJobDetail, IReadOnlyCollection <ITrigger> > dictionary = new Dictionary <IJobDetail, IReadOnlyCollection <ITrigger> > {
                { job, new ReadOnlyCollection <ITrigger>(new List <ITrigger>((HashSet <ITrigger>)triggers)) }
            };

            JobStore.StoreJobsAndTriggers(dictionary, true);
        }