Dependency Injection and the Strategy Pattern

As far as I can tell, this question is about run-time selection or mapping of one of several candidate Strategies.

There’s no reason to rely on a DI Container to do this, as there are at least three ways to do this in a container-agnostic way:

My personal preference is the Partial Type Name Role Hint.

Leave a Comment