Beispiel #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();
        }
Beispiel #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();
        }
Beispiel #3
0
 public NamedTypesRegistry(NamedTypesRegistry parent)
 {
     this.parent = parent;
     registeredKeys = new Dictionary<Type, List<string>>();
 }
 public RegisteredNamesPolicy(NamedTypesRegistry registry)
 {
     this.registry = registry;
 }
Beispiel #5
0
 public NamedTypesRegistry(NamedTypesRegistry parent)
 {
     this.parent    = parent;
     registeredKeys = new Dictionary <Type, List <string> >();
 }
Beispiel #6
0
 public RegisteredNamesPolicy(NamedTypesRegistry registry)
 {
     this.registry = registry;
 }