예제 #1
0
        public static void Main(string[] args)
        {
            IUnityContainer container = new UnityContainer();

            ProjectContainer.RegisterElements(container);

            if (GetHelp(args))
            {
                IHelp help = container.Resolve <IHelp>();
                help.Write();
                System.Environment.Exit(-1);
            }
            else
            {
                IGenerateFiles generateFiles = container.Resolve <IGenerateFiles>();
                bool           isRun         = generateFiles.Run();

                if (isRun)
                {
                    System.Environment.Exit(0);
                }
                else
                {
                    System.Environment.Exit(-1);
                }
            }
        }
예제 #2
0
        public static void Main(string[] args)
        {
            IUnityContainer container = new UnityContainer();

            ProjectContainer.RegisterElements(container);

            if (GetHelp(args))
            {
                IHelp help = container.Resolve <IHelp>();
                help.Write();
                System.Environment.Exit(-1);
            }
            else
            {
                IBaseClient baseClient = container.Resolve <IBaseClient>();
                baseClient.Run();
            }
        }