Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

Why does Microsoft create specific Extension Methods?

$
0
0

I wrote my first Extension Method a few days ago.  Extension Methods are a great idea.

But I don't understand why Microsoft supplies specific Extension Methods.  The documentation for the String Class, for example, has many.  But if you are Microsoft why not supply regular Methods?  I used to avoid even looking at Extension Methods because I hadn't done any research and thus didn't understand what they were.  

Mostly I am just curious.  But I wonder too if maybe there is something I don't understand about Extension Methods which explains why Microsoft seems to (at least sometimes) prefer Extension Methods to regular Methods.

Thanks,  Bob


Viewing all articles
Browse latest Browse all 8156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>