Exemplo n.º 1
0
        public SingletonScanner(IReflection reflection, ILogger logger, ISingletonManager singletonManager)
        {
            Argument.NotNull(() => reflection);
            Argument.NotNull(() => logger);
            Argument.NotNull(() => singletonManager);

            this.reflection       = reflection;
            this.logger           = logger;
            this.singletonManager = singletonManager;
        }
        public SingletonScanner(IReflection reflection, ILogger logger, ISingletonManager singletonManager)
        {
            Argument.NotNull(() => reflection);
            Argument.NotNull(() => logger);
            Argument.NotNull(() => singletonManager);

            this.reflection = reflection;
            this.logger = logger;
            this.singletonManager = singletonManager;
        }
Exemplo n.º 3
0
        private App()
        {
            var logger  = new UnityLogger();
            var factory = new Factory("App", logger);

            factory.Dep <ILogger>(logger);
            factory.AutoRegisterTypes();

            this.Factory          = factory;
            this.singletonManager = factory.AutoInstantiateSingletons();
            this.singletonManager.Startup();
        }