castle-windsor Questions
1
Solved
I have two interfaces:
public interface IQuery<TResult> { }
public interface IQueryHandler<in TQuery, out TResult>
where TQuery : IQuery<TResult>
{
TResult Handle(TQuery q);
}
...
Quinquevalent asked 16/12, 2014 at 16:48
1
Is it possible to configure Unity to either detect a circular reference or to intercept the type resolver to display some debugging information?
Example
Here are a couple of interfaces and class...
Hormonal asked 19/3, 2013 at 11:3
1
Solved
I have class that has dependency on string:
public class Person
{
private readonly string _name;
public Person(string name)
{
if (name == null) throw new ArgumentNullException("name");
_name...
Geoffrey asked 16/12, 2014 at 14:53
3
Via Windsor I register multiple implementation types to a single interface type :
public class WindsorInstaller : IWindsorInstaller
{
public void Install(IWindsorContainer container, IConfigurat...
Allyson asked 5/3, 2014 at 2:50
2
Solved
I have a solution in which I use IoC (windsor).
The projects in the solution are as follows:
Interfaces - Holds all the interface contracts I'll use.
IoC.Installers - Holds all the installers for...
Precondition asked 9/11, 2014 at 11:12
3
Solved
How to configure Interface having multiple concrete implementation using Castle Windsor (using code). Below is the sample code.
public interface ICostCalculator
{
double CalculateTotal(Order orde...
Patriliny asked 22/3, 2011 at 12:14
6
Solved
I'm considering using Castle Windsor's Interceptors to cache data for helping scale an asp.net site.
Does anyone have any thoughts/experience with doing this?
Minor clarification:
My intention wa...
Prompter asked 18/9, 2008 at 16:53
2
Solved
Assume that I have multiple objects registered in the container, all implementing the same interface:
container.Register(
Component.For<ITask>().ImplementedBy<Task1>(),
Component.For...
Hooded asked 27/10, 2014 at 8:30
2
I am trying to wire up my Web Api project to use Castle Windsor for IoC
I have done that for my controllers by following this excellent article.
I am now trying to get dependencies injected into ...
Dreeda asked 24/10, 2012 at 16:42
3
Solved
Having read and googled to the point of exhaustion, I feel as though I may need some guidance.
This may partly be because of the introduction of Castle Windsor 3.0, however most of the blog posts,...
Asperity asked 21/4, 2012 at 20:14
1
Solved
I'm going to preface this question with the statement: I know the following is bad design, but refactoring is not currently an option, ideally it should be done using interceptors.
I am working on...
Benuecongo asked 2/9, 2014 at 19:52
2
Solved
One of the great advantages of Owin is that it has no dependency on System.Web. How on earth do I setup the DI if WebApi clearly requires something along those lines:
var config = new HttpConfigur...
Douglassdougy asked 21/8, 2014 at 8:26
1
Solved
I'm starting using Windsor, and I want to understand when should I use container and when kernel. E.g.
var c = new WindsorContainer();
c.Register(Component.For<ITt>().ImplementedBy<Tt>(...
Groundspeed asked 14/8, 2014 at 7:48
2
Solved
I have 2 types of ViewModel's
public class ViewModelA
{
IService service;
private ViewModelB childViewModel;
public ViewModelA(IService service,ViewModelB childViewModel)
{
this.service...
Avogadro asked 31/7, 2014 at 16:41
1
Solved
Why would you use Castle Windsor factory auto implementation feature: AsFactory() rather then asking for needed interface?
Example:
container.Register(Component.For<IEmailSender>().Implemen...
Benedicite asked 31/7, 2014 at 15:14
4
Solved
Reading this blog post it mentions you can get your DI container to automatically subscribe to events if it implements IHandle<>. That is exactly what I'm trying to accomplish.
Here is what ...
Addition asked 12/8, 2011 at 13:12
1
I have an abstract base class which contains several methods, of which one I need to intercept at all times. The base class can be inherited by user defined classes and registered with the containe...
Gutturalize asked 23/7, 2014 at 7:17
2
Solved
I know this has been discussed ad nauseum...but I have an issue with the way Windsor is tracking Transient IDisposable objects.
I understand the benefits of letting Windsor manage my IDiposables.....
Aalto asked 21/7, 2011 at 20:34
4
Solved
I'd like to configure the Windsor container so that a single, singleton-style instance can provide two or more services through the container.
I've found that using the same type in multiple compo...
Khalil asked 26/3, 2009 at 1:57
3
Solved
I have a component registered in Castle Windsor as a singleton. This object is being used in many other places within my application which is multithreaded.
Is it possible that the two objects wi...
Felid asked 29/5, 2014 at 11:57
2
Solved
What are the differences between these two life cycles?
Let's say my MVC controller is being supplied with an object that was configured as transient, then when someone visits a method in that con...
Terpineol asked 22/3, 2014 at 7:42
1
Solved
I'm getting the 'No parameterless constructor defined for this object' on my controller when the controller and its dependencies are being registered accordingly via (DI/IoC) pattern using Castle W...
Counterintelligence asked 7/2, 2014 at 15:16
2
I have a Castle Interceptor that I'm trying to apply via attributes. It's working great when I apply my Interceptor attribute at class-level, but it's not working at all when I'm applying at method...
Skaw asked 15/1, 2014 at 21:11
2
Solved
I am a Castle Winsor Noob. I have a WebForm project that is a hot mess. I am trying to resolve a dependency to test user registration. How do I get to the current WindsorContainer?
IWindsorContain...
Publicspirited asked 14/1, 2014 at 19:42
1
Solved
I'm just starting out with SignalR, and have created a custom resolver for SignalR, so I can use Castle Windsor to inject dependencies via hub constructors.
I kind of assumed that I would only nee...
Garble asked 14/1, 2014 at 10:38
© 2022 - 2024 — McMap. All rights reserved.