/// <summary>
 /// Notify of step start. If e.Cancel is True, then cancel operation.
 /// </summary>
 protected virtual void OnStepStarting(AdapterProgressCancelEventArgs e)
 {
     if (StepStarting != null)
     {
         StepStarting(this, e);
     }
 }
        /// <summary>
        /// Notify of step start. If return value is True, then cancel operation.
        /// </summary>
        /// <param name="context">The method name or workflow activty.</param>
        /// <param name="message">Descriptive message.</param>
        /// <param name="status">Overall Package status indicator.</param>
        /// <param name="id">Message Id.</param>
        /// <param name="severity">Message/error severity.</param>
        /// <param name="ex">Current exception (optional).</param>
        /// <returns>AdapterProgressCancelEventArgs.Cancel value.</returns>
        protected virtual bool OnStepStarting(string context, string message, PackageStatus status, int id, int severity, Exception ex)
        {
            AdapterProgressCancelEventArgs e =
                new AdapterProgressCancelEventArgs(context, message, status, id, severity, false, ex);

            OnStepStarting(e);

            return(e.Cancel);
        }