Private Extension Methods
Posted by: K. Scott Allen,
on 06 Oct 2009 |
View original | Bookmarked: 0 time(s)
I spent a few hours on a failed experiment recently, but one concept that outlived the spike was how to make use of private extension methods. By private I mean the extension methods have a private access modifier and are only visible inside of a single class. Sounds pointless, right? Consider the code in the following class that is attempting to build multiple script tags out of the names of JavaScript files embedded as resources in an assembly. public static class ScriptHelper
{
public...