Example #1
0
        /// <summary>
        /// Main entry point
        /// </summary>
        /// <param name="args">Command line arguments passed in</param>
        /// <returns>Empty Task that completes when the application has finished</returns>
        /// <exception cref="ArgumentException">Exception thrown when the program was called with invalid argumente</exception>
        static void Main(string[] args)
        {
            ProviderBuilder  builder   = new ProviderBuilder();
            IServiceProvider container = builder.AutowireAssembly(Assembly.GetExecutingAssembly()).Build();
            Arguments        arguments = new Arguments(args);

            if (!arguments.HasArgument("p"))
            {
                throw new ArgumentException("No problem specified with argument p");
            }

            Program.Autorun(container, arguments);
        }