Example #1
0
        public MemoryPoolBindingFinalizer(
            BindInfo bindInfo, FactoryBindInfo factoryBindInfo, MemoryPoolBindInfo poolBindInfo)
            : base(bindInfo)
        {
            // Note that it doesn't derive from MemoryPool<TContract>
            // when used with To<>, so we can only check IMemoryPoolBase
            Assert.That(factoryBindInfo.FactoryType.DerivesFrom <IMemoryPool>());

            _factoryBindInfo = factoryBindInfo;
            _poolBindInfo    = poolBindInfo;
        }
 public FactoryFromBinderBase(
     DiContainer bindContainer, Type contractType, BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(bindInfo)
 {
     FactoryBindInfo = factoryBindInfo;
     BindContainer   = bindContainer;
     ContractType    = contractType;
     factoryBindInfo.ProviderFunc =
         (container) => new TransientProvider(
             ContractType, container, BindInfo.Arguments, BindInfo.ContextInfo, BindInfo.ConcreteIdentifier);
 }
        public FactorySubContainerBinderBase(
            DiContainer bindContainer, BindInfo bindInfo, FactoryBindInfo factoryBindInfo, object subIdentifier)
        {
            FactoryBindInfo = factoryBindInfo;
            SubIdentifier   = subIdentifier;
            BindInfo        = bindInfo;
            BindContainer   = bindContainer;

            // Reset so we get errors if we end here
            factoryBindInfo.ProviderFunc = null;
        }
Example #4
0
 public FactoryFromBinder(
     DiContainer container, BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(container, typeof(TContract), bindInfo, factoryBindInfo)
 {
 }
Example #5
0
 public FactorySubContainerBinder(
     DiContainer bindContainer, BindInfo bindInfo, FactoryBindInfo factoryBindInfo, object subIdentifier)
     : base(bindContainer, bindInfo, factoryBindInfo, subIdentifier)
 {
 }
 public FactoryToChoiceBinder(
     DiContainer bindContainer, BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(bindContainer, bindInfo, factoryBindInfo)
 {
 }
 public FactorySubContainerBinderWithParams(
     BindInfo bindInfo, FactoryBindInfo factoryBindInfo, object subIdentifier)
     : base(bindInfo, factoryBindInfo, subIdentifier)
 {
 }
 public MemoryPoolMaxSizeBinder(
     DiContainer bindContainer, BindInfo bindInfo, FactoryBindInfo factoryBindInfo, MemoryPoolBindInfo poolBindInfo)
     : base(bindContainer, bindInfo, factoryBindInfo, poolBindInfo)
 {
 }
 public FactoryFromBinder(
     BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(bindInfo, factoryBindInfo)
 {
 }
 public FactoryToChoiceIdBinder(
     BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(bindInfo, factoryBindInfo)
 {
 }
 public FactoryFromBinderUntyped(
     DiContainer bindContainer, Type contractType, BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(bindContainer, contractType, bindInfo, factoryBindInfo)
 {
 }
Example #12
0
 public FactoryToChoiceIdBinder(
     DiContainer container, BindInfo bindInfo, FactoryBindInfo factoryBindInfo)
     : base(container, bindInfo, factoryBindInfo)
 {
 }
 public MemoryPoolInitialSizeBinder(
     BindInfo bindInfo, FactoryBindInfo factoryBindInfo, MemoryPoolBindInfo poolBindInfo)
     : base(bindInfo, factoryBindInfo, poolBindInfo)
 {
 }