public static string ReadLine(TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
        {
            string value   = null;
            bool   canStep = true;

            using (Timer timer = new Timer((a) => {
                if (canStep)
                {
                    animation.Step();
                }
            }))
            {
                timer.Change(0, Convert.ToInt32(animationStepFrequency.TotalMilliseconds));
                value = ConsoleApp.ReadLine(timeOut);
                timer.Change(Timeout.Infinite, 0);
            }
            return(value);
        }
        public static Char ReadChar(TimeSpan timeOut, Char timeOutValue, IConsoleAnimation animation, TimeSpan animationStepFrequency)
        {
            Char value   = default(char);
            bool canStep = true;

            using (Timer timer = new Timer((a) =>
            {
                if (canStep)
                {
                    animation.Step();
                }
            }))
            {
                timer.Change(0, Convert.ToInt32(animationStepFrequency.TotalMilliseconds));
                if (!ConsoleApp.ReadChar(timeOut, out value))
                {
                    value = timeOutValue;
                }

                timer.Change(Timeout.Infinite, 0);
            }
            return(value);
        }
 public static Char ReadChar(TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return(ConsoleApp.ReadChar(timeOut, default(char), animation, animationStepFrequency));
 }
 public static ConsoleKeyInfo ReadKey(TimeSpan timeOut, ConsoleKeyInfo timeOutValue, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return(ConsoleApp.ReadKey(false, timeOut, timeOutValue, animation, animationStepFrequency));
 }
 public static ConsoleKeyInfo ReadKey(bool intercept, TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return(ConsoleApp.ReadKey(intercept, timeOut, default(ConsoleKeyInfo), animation, animationStepFrequency));
 }
 public static string ReadLine(TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     string value = null;
     bool canStep = true;
     using (Timer timer = new Timer((a) => {
         if (canStep)
             animation.Step();
     }))
     {
         timer.Change(0, Convert.ToInt32(animationStepFrequency.TotalMilliseconds));
         value = ConsoleApp.ReadLine(timeOut);
         timer.Change(Timeout.Infinite, 0);
     }
     return value;
 }
 public static ConsoleKeyInfo ReadKey(bool intercept, TimeSpan timeOut, ConsoleKeyInfo timeOutValue, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     ConsoleKeyInfo value = default(ConsoleKeyInfo);
     bool canStep = true;
     using (Timer timer = new Timer((a) =>
     {
         if (canStep)
             animation.Step();
     }))
     {
         timer.Change(0, Convert.ToInt32(animationStepFrequency.TotalMilliseconds));
         if (!ConsoleApp.ReadKey(intercept, timeOut, out value))
             value = timeOutValue;
         timer.Change(Timeout.Infinite, 0);
     }
     return value;
 }
 public static ConsoleKeyInfo ReadKey(bool intercept, TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return ConsoleApp.ReadKey(intercept, timeOut, default(ConsoleKeyInfo), animation, animationStepFrequency);
 }
 public static ConsoleKeyInfo ReadKey(TimeSpan timeOut, ConsoleKeyInfo timeOutValue, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return ConsoleApp.ReadKey(false, timeOut, timeOutValue, animation, animationStepFrequency);
 }
 public static Char ReadChar(TimeSpan timeOut, IConsoleAnimation animation, TimeSpan animationStepFrequency)
 {
     return ConsoleApp.ReadChar(timeOut, default(char), animation, animationStepFrequency);
 }