1
我想通过指定System.Type
来注册实现。以下是我可以使用温莎城堡做到这一点:StructureMap:如何注册System.Type实现
var type = typeof(MessageQueueProcessorImpl); // configurable
container.Register(
Component.For<MessageQueueProcessorBase>()
.ImplementedBy(type)
我试着StructureMap明显:
var type = typeof(MessageQueueProcessorImpl); // configurable
For<MessageQueueProcessorBase>()
.Use(type) // <-- not accepted
这可能与StructureMap(2.6.4.1)?
这是如此明显,当我看着它。感谢您及时的回复! –