Unity Dependency Injection for WCF services

后端 未结 3 1325
借酒劲吻你
借酒劲吻你 2020-12-17 16:13

Can someone direct me to a good example of Unity Dependency Injection for WCF services? Any blog or msdn article will also help.

3条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-17 16:50

    This answer gives an example on how to enable DI in WCF with Castle Windsor.

    Just replace the IWindsorContainer with an IUnityContainer in the example and you should be all set, although you may also want to change the class names from WindsorXyz to UnityXyz :)

提交回复
热议问题