ILoggable

A place to keep my thoughts on programming

Tag Archives: Extension method

Searching a Tree of Objects with Linq, Revisited

A while back, I wrote about searching through a tree using linq to objects. That post was mostly snippets of code about delegates, lambda’s, yield and how it applies to linq — more a technical exploration than an example. So … Continue reading

June 11, 2009 .net , , , , , ,

IEnumerable.ForEach()

I keep wanting to do ForEach() on a collection, and noticed that it was inconsistent whether that extension method was available or not. I always figured that i wasn’t importing the right namespace, and blamed ReSharper for not being smart … Continue reading

October 3, 2008 .net , ,

Epoch DateTime conversion Extension Methods

Interop with unix often requires dealing with Epoch or Unix time, or the number of seconds since January 1st, 1970 UTC. And if you throw java in the mix, then epoch becomes milliseconds, since they define System.currentTimeMillis() as the number … Continue reading

March 8, 2008 .net , , ,

Stupid ExtensionMethod tricks

I have yet to decide whether Extension Methods in C# are a boon or bane. I’ve already several times, been frustrated by Intellisense not showing me a method that was legal somewhere else, until I could figure out what using … Continue reading

November 20, 2007 .net, geek , ,