/// <summary>
        /// Initializes a new instance of the <see cref="NinjectObjectBuilder"/> class.
        /// </summary>
        /// <remarks>
        /// Uses the default object builder property <see cref="propertyHeuristic"/> 
        /// <see cref="ObjectBuilderPropertyHeuristic"/>.
        /// </remarks>
        /// <param name="kernel">
        /// The kernel.
        /// </param>
        public NinjectObjectBuilder(IKernel kernel)
        {
            this.kernel = kernel;

            this.RegisterNecessaryBindings();

            this.propertyHeuristic = this.kernel.Get<IObjectBuilderPropertyHeuristic>();

            this.AddCustomPropertyInjectionHeuristic();

            this.ReplacePropertyInjectionStrategyWithCustomPropertyInjectionStrategy();
        }
Example #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="NinjectObjectBuilder"/> class.
        /// </summary>
        /// <remarks>
        /// Uses the default object builder property <see cref="propertyHeuristic"/>
        /// <see cref="ObjectBuilderPropertyHeuristic"/>.
        /// </remarks>
        /// <param name="kernel">
        /// The kernel.
        /// </param>
        public NinjectObjectBuilder(IKernel kernel)
        {
            this.kernel = kernel;

            this.RegisterNecessaryBindings();

            this.propertyHeuristic = this.kernel.Get <IObjectBuilderPropertyHeuristic>();

            this.AddCustomPropertyInjectionHeuristic();

            this.ReplacePropertyInjectionStrategyWithCustomPropertyInjectionStrategy();
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="NinjectObjectBuilder"/> class.
        /// </summary>
        /// <remarks>
        /// Uses the default object builder property <see cref="propertyHeuristic"/>
        /// <see cref="ObjectBuilderPropertyHeuristic"/>.
        /// </remarks>
        /// <param name="kernel">
        /// The kernel.
        /// </param>
        public NinjectObjectBuilder(IKernel kernel)
        {
            this.kernel = kernel;

            this.RegisterNecessaryBindings();

            this.propertyHeuristic = this.kernel.Get <IObjectBuilderPropertyHeuristic>();

            this.AddCustomPropertyInjectionHeuristic();

            this.kernel.Bind <NinjectChildContainer>().ToSelf().Named("Container").DefinesNamedScope("Container");
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="NinjectObjectBuilder"/> class.
        /// </summary>
        /// <remarks>
        /// Uses the default object builder property <see cref="propertyHeuristic"/> 
        /// <see cref="ObjectBuilderPropertyHeuristic"/>.
        /// </remarks>
        /// <param name="kernel">
        /// The kernel.
        /// </param>
        public NinjectObjectBuilder(IKernel kernel)
        {
            this.kernel = kernel;

            this.RegisterNecessaryBindings();

            this.propertyHeuristic = this.kernel.Get<IObjectBuilderPropertyHeuristic>();

            this.AddCustomPropertyInjectionHeuristic();

            this.ReplacePropertyInjectionStrategyWithCustomPropertyInjectionStrategy();

            this.kernel.Bind<NinjectChildContainer>().ToSelf().Named("Container").DefinesNamedScope("Container");
        }