Beispiel #1
0
        /// <summary>
        ///     Starts the task on the given DispatcherBase (Dispatcher or TaskDistributor).
        /// </summary>
        /// <param name="target">The DispatcherBase to work on.</param>
        /// <returns>This task</returns>
        public CustomTask Run(CustomTaskDispatcherBase target)
        {
            if (target == null)
            {
                return(Run());
            }

            target.Dispatch(this);
            return(this);
        }
Beispiel #2
0
 /// <summary>
 ///     Runs the specified target.
 /// </summary>
 /// <param name="target">The target.</param>
 /// <returns></returns>
 public new CustomTask <T> Run(CustomTaskDispatcherBase target)        // TODO why 'new' ?
 {
     ((CustomTask)this).Run(target);
     return(this);
 }