Beispiel #1
0
        static void Main(string[] args)
        {
            var objectBuilder = new ObjectBuilder(UnityConfig.RegisterTypes);

            LoggingConfig.Initialise(objectBuilder.GetContainer());
            Bootstrapper.Initialise();

            if (args.Length != 1)
            {
                Usage();
                return;
            }
            var command = args[0];

            if (!ValidParameters.Contains(command))
            {
                Usage();
                return;
            }

            if (command.SafeEquals("All"))
            {
                foreach (var cmd in Commands)
                {
                    ExecuteCommand(cmd, objectBuilder);
                }
            }
            else
            {
                ExecuteCommand(command, objectBuilder);
            }

            System.Console.ReadLine();
        }