Example #1
0
        private void InitializeBuilderState()
        {
            registeredNames = new NamedTypesRegistry(ParentNameRegistry);
            extensions      = new List <UnityContainerExtension>();

            lifetimeContainer   = new LifetimeContainer();
            strategies          = new StagedStrategyChain <UnityBuildStage>(ParentStrategies);
            buildPlanStrategies = new StagedStrategyChain <UnityBuildStage>(ParentBuildPlanStrategies);
            policies            = new PolicyList(ParentPolicies);
            policies.Set <IRegisteredNamesPolicy>(new RegisteredNamesPolicy(registeredNames), null);

            cachedStrategies     = null;
            cachedStrategiesLock = new object();
        }
Example #2
0
        private void InitializeBuilderState()
        {
            registeredNames = new NamedTypesRegistry(ParentNameRegistry);
            extensions = new List<UnityContainerExtension>();

            lifetimeContainer = new LifetimeContainer();
            strategies = new StagedStrategyChain<UnityBuildStage>(ParentStrategies);
            buildPlanStrategies = new StagedStrategyChain<UnityBuildStage>(ParentBuildPlanStrategies);
            policies = new PolicyList(ParentPolicies);
            policies.Set<IRegisteredNamesPolicy>(new RegisteredNamesPolicy(registeredNames), null);

            cachedStrategies = null;
            cachedStrategiesLock = new object();
        }
Example #3
0
 public NamedTypesRegistry(NamedTypesRegistry parent)
 {
     this.parent = parent;
     registeredKeys = new Dictionary<Type, List<string>>();
 }
 public RegisteredNamesPolicy(NamedTypesRegistry registry)
 {
     this.registry = registry;
 }
Example #5
0
 public NamedTypesRegistry(NamedTypesRegistry parent)
 {
     this.parent    = parent;
     registeredKeys = new Dictionary <Type, List <string> >();
 }
Example #6
0
 public RegisteredNamesPolicy(NamedTypesRegistry registry)
 {
     this.registry = registry;
 }