the following works with 3.0, but throws an exception in 3.1
var c = new WindsorContainer();
c.Register(Classes.From(typeof(Dictionary,)).Pick().WithServiceBase().WithServiceAllInterfaces());
i'm not sure what the actual issue is, but exception message complained
about ICollectionKeyValuePair,
Thanks.
Can you create an actual failing test?
Thanks
@k
On Jul 11, 2012 8:09 AM, bling bailey.l...@gmail.com wrote:
the following works with 3.0, but throws an exception in 3.1
var c = new WindsorContainer();
[Test]
public void RegisterGenericType_WithServiceAllInterfaces()
{
Assert.DoesNotThrow(() =
Kernel.Register(Classes.From(typeof(Dictionary,)).Pick().WithServiceAllInterfaces()));
}
On Tuesday, July 10, 2012 6:10:57 PM UTC-4, Krzysztof Koźmic wrote:
Thanks.
Thanks,
I've got it reproduced. Do you mind logging this as a bug in the issue
tracker at issues.castleproject.org ?
cheers,
@K
On 11/07/12 8:28 AM, bling wrote:
[Test]
public void RegisterGenericType_WithServiceAllInterfaces()
{
Assert.DoesNotThrow(() =
So leaving this example aside, the reason for this behavior is that
Windsor sees you're registering your type as IEnumerableSomeValueType
which while used to be allowed previously is not really something you'd
want to have as a service.
So can you help me better understand in your actual
I don't.
The way I have my application is the typical:
- Register explicitly, i.e.
Component.ForIFoo().ImplementedByFoo()..., for things that I need
explicit.
- Then, some convention based things. Like
Classes.Pick().BasedOnBar().WithServiceBase().
- Finally, the catch all,
Yep, pretty much.
On Tuesday, July 10, 2012 11:56:18 PM UTC-4, Krzysztof Koźmic wrote:
Right,
so what you really want is not All interfaces but rather service
interfaces that would be like all interfaces but filtering out noise
that is all the ISerializable, IDisposable, IComparable,
Ok, so what do you say on adding a method that behaves like
AllInterfaces but filters out all interfaces that are in System
namespaces (or one of its subnamespaces)?
I'm just not sure what would be a good name for the method in the API...
WithService.NonSystemInterfaces() just doesn't sound