Click here to Skip to main content
12,630,025 members (32,358 online)
Click here to Skip to main content

Stats

57.8K views
571 downloads
34 bookmarked
Posted

Poor Man's LINQ in Visual Studio 2005

, 29 Oct 2010 MIT
A way to use LINQ to Objects in C# 2.0 with .NET Framework 2.0
// Permission is hereby granted, free of charge, to any person obtaining
// a copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to
// permit persons to whom the Software is furnished to do so, subject to
// the following conditions:
// 
// The above copyright notice and this permission notice shall be
// included in all copies or substantial portions of the Software.
// 
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
//
// Authors:
//        Marek Safar (marek.safar@gmail.com)
//

using System;
using System.Collections.Generic;
//using System.Linq.Expressions;

namespace Compatibility.Linq
{
	public interface IOrderedSequence<TElement> : IEnumerable<TElement>
	{
		IOrderedSequence<TElement> CreateOrderedSequence<TKey> (Func<TElement, TKey> selector, IComparer<TKey> comparer, bool descending);
	}
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The MIT License

Share

About the Author

Qwertie
Software Developer None
Canada Canada
Since I started programming when I was 11, I wrote the SNES emulator "SNEqr", the FastNav mapping component, the open-source LeMP preprocessor for C#, the LLLPG parser generator, and LES, the syntax tree interchange format, among other things.

In my spare time I work on the Language of your choice (Loyc) initiative, which is about investigating ways to improve interoperability between programming languages.

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.161205.3 | Last Updated 29 Oct 2010
Article Copyright 2008 by Qwertie
Everything else Copyright © CodeProject, 1999-2016
Layout: fixed | fluid