Exemplo n.º 1
0
        public void Run()
        {
            var archiverThread =
                new Thread(
                    () =>
                    _archiver.Process(_parameters.InputFilePath, _parameters.OutputFilePath, _parameters.Operation))
            {
                Name     = "GZipArchiver",
                Priority = ThreadPriority.AboveNormal
            };

            archiverThread.Start();

            using (var spinner = new ConsoleSpinner())
            {
                while (archiverThread.IsAlive)
                {
                    spinner.Turn();
                }
            }

            if (!_isTerminated)
            {
                OutputResult();
            }
        }