TraktPlugin.Configuration.ParseCommandLine C# (CSharp) Méthode

ParseCommandLine() private méthode

private ParseCommandLine ( string args ) : void
args string
Résultat void
        private void ParseCommandLine(string[] args)
        {
            if (args == null)
                return;

            foreach (var argument in args)
            {
                switch (argument.ToLower().TrimStart('-'))
                {
                    case "silentmode":
                        SilentMode = true;
                        break;

                    case "sync":
                        AutoSync = true;
                        break;

                    case "closeaftersync":
                        AutoCloseAfterSync = true;
                        break;
                }
            }

            TraktLogger.Info("Command Line Options Set, SilentMode = '{0}', AutoSync = '{1}', CloseAfterSync = '{2}'", SilentMode, AutoSync, AutoCloseAfterSync);
        }