makerofthings7
makerofthings7

Reputation: 61463

Need complete DI sample for WCF

Does anyone have a complete and working DI sample for WCF?

Every sample I find just gets me more confused. Does anyone know of a complete and working standalone simple sample that works with the built in stuff?

Maybe once I get a handle of the built in stuff, I can move on to different DI frameworks such as StructureMap or Unity with WCF.

My MVC project is currently using Unity for all its DI.

Upvotes: 2

Views: 1075

Answers (5)

tjp69
tjp69

Reputation: 1088

There is a fully working downloadable sample here on Codeplex. It uses the Unity.WCF NuGet package, so it's really the kind of slam dunk example you are looking for.

Upvotes: 0

Mark Seemann
Mark Seemann

Reputation: 233150

The code download for my book Dependency Injection in .NET contains a full, working example.

However, most of what you'll need to know is explained in this answer: Injecting data to a WCF service

Upvotes: 1

Ladislav Mrnka
Ladislav Mrnka

Reputation: 364279

I recommend this one. I have already used it and it is fully working.

Upvotes: 2

Paul
Paul

Reputation: 36319

This one is the most straightforward one I've found.

Upvotes: 0

Related Questions