Beispiel #1
0
        /// <summary>
        /// Generates the confirmation step.
        /// </summary>
        /// <returns></returns>
        private TextDisplayStep GenerateConfirmation()
        {
            var sep  = Environment.NewLine + "> ";
            var step = new TextDisplayStep(string.Empty, "Confirm settings");

            step.StepReachedHandler += () =>
            {
                var details = string.Join(sep, settings.ToArray());
                step.Text = "The following settings will be applied:" + sep + details;
            };
            return(step);
        }
Beispiel #2
0
        /// <summary>
        /// Generates the confirmation step.
        /// </summary>
        /// <returns></returns>
        private IStep GenerateConfirmation()
        {
            var sep  = Environment.NewLine + "> ";
            var step = new TextDisplayStep(string.Empty, "Confirm settings");

            step.StepReachedHandler += () =>
            {
                var details = string.Join(sep, settings.ToArray());
                step.Text = "The following settings will be applied:" + sep + details;
            };
            step.NextHandler += () =>
            {
                if (security is InternalServerSecurity)
                {
                    (security as InternalServerSecurity).AuditLoggers.AddRange(loggers.Values);
                }
                configuration.Security = security;
                configureProjects.Invoke();
                return(true);
            };
            return(step);
        }