Пример #1
0
        static void Main(string[] args)
        {
            OurDI container = new OurDI();

            Configure(container);


            DoubleWorker doubleWorker = container.Resolve <DoubleWorker>();
            StringWorker stringWorker = container.Resolve <StringWorker>();

            doubleWorker.Work();
            stringWorker.Work();

            Console.Read();
        }
Пример #2
0
 static void Configure(OurDI container)
 {
     container.Set <ILogger, Logger>();
 }