StructureMap 4.0 came out earlier this month, thanks to the continuing work of Jeremy Miller. It’s a Big Deal since it supports .NET Core and ASP.NET 5 (among other things), but unfortunately a few things moved around, and Heroic.Web.IoC was broken (your StructureMap-related code was probably broken, too). Fortunately, the fixes are easy, and Heroic.Web.IoC…
try-catch-FAIL
Tag: <span>StructureMap</span>
The Decorator Pattern, Done Right, With StructureMap 3.0
Back in 2012, I wrote a post about how to use the decorator pattern with StrutureMap. Since then, StructureMap 3.0 has been released, and it’s actually much easier to apply decorators now! Read on, and I’ll show you. [more] Back in 2012… The StructureMap 2.6.x API didn’t provide a clean way to decorate things. You…
Ditching StructureMap’s ObjectFactory
Another question people ask after they’ve watched my App Framework course at Pluralsight is, “What should I do now that StructureMap’s ObjectFactory has been deprecated?” Actually, it’s more like a cry for help rather than a question. It goes like this: “AAHHHHHH OBJECT FACTORY IS GOING AWAY WHAT DO I DO?? AHHHHHHHHHHHHHHHHHH!!” Or at least…
The Decorator Pattern, Done Right, With StructureMap
One of the cool bits of black magic I showed during my “StructureMapping Your Way to Better Software” talk was an extension method for registering decorators using StructureMap. In this post, I’ll show you how it works. [more] EnrichWith Says What? StructureMap actually supports the decorator pattern right out of the box. This functionality…