예제 #1
0
        public static object ResolveDummyPopulation(Autofac.IContainer container)
        {
            using (var scope = container.BeginLifetimeScope())
            {
                scope.Resolve <D1>();
                scope.Resolve <D2>();
                scope.Resolve <D3>();
                scope.Resolve <D4>();
                scope.Resolve <D5>();
                scope.Resolve <D6>();
                scope.Resolve <D7>();
                scope.Resolve <D8>();
                scope.Resolve <D9>();
                scope.Resolve <D10>();
                scope.Resolve <D11>();
                scope.Resolve <D12>();

                scope.Resolve <D13>();
                scope.Resolve <D14>();
                scope.Resolve <D15>();
                scope.Resolve <D16>();
                scope.Resolve <D17>();
                scope.Resolve <D18>();
                scope.Resolve <D19>();
                return(scope.Resolve <D20>());
            }
        }
예제 #2
0
 public void WarmUp()
 {
     _msDi        = PrepareMsDi();
     _dryioc      = PrepareDryIoc();
     _dryIocMsDi  = PrepareDryIocMsDi();
     _grace       = PrepareGrace();
     _graceMsDi   = PrepareGraceMsDi();
     _autofac     = PrepareAutofac();
     _autofacMsDi = PrepareAutofacMsDi();
 }
예제 #3
0
 public static object Measure(Autofac.IContainer container)
 {
     using (var scope = container.BeginLifetimeScope())
         return(scope.Resolve <R>());
 }