[Code Plex] NLinq


NLinq
http://www.codeplex.com/nlinq
より。



Project Description
NLinq is a framework focusing on reimplementing the Linq functionnalities in Visual Studio .Net 2003 and Visual Studio 2005 (C# & VB .Net) by providing a Linq grammar parser and a "Linq To Objects" execution environment. With NLinq you can take advantage of major C# 3.0 features right now, without requiring it.

NLinqは、Linqの文法パーサとLinq To Objectの実行環境を提供することによって、Visual Studio .Net 2003/2005(C#,VB.Net)でLinqの機能を実装可能としている。
NLinqによって、C#3.0を使用せずに、その主要機能をすぐに使うことができる。


使用方法

            query = new NLinqQuery(
                @"  from m in methods
                    where !m.IsStatic
                    orderby m.Name
                    group m by m.Name into g
                    select new { MethodName = g.Key, Overloads = g.Count() }");
 
            linq = new LinqToMemory(query);
            linq.AddSource("methods", typeof(string).GetMethods());
 
            foreach (object o in linq.Enumerate())
            {
                Console.WriteLine(o);
            }


詳細は、上記のサイトを参照