Getting Started with LINQ
SampleQueries: This is the most important sample and contains about 500 examples of how to use each of the query operators in LINQ to Objects, LINQ to SQL, LINQ to XML and LINQ to DataSet.
SimpleLinqToObjects: The hello world of the LINQ samples. This shows you how easy it is to do simple queries of in-memory objects using LINQ to Objects.
LinqToNorthwind: A basic example of how to use LINQ To SQL to query a database.
SimpleLinqToXml: Get started using LINQ to XML.
WinFormsDataBinding: Learn how to display LINQ queries with grids in a Windows form. It includes a one to many query example.
XQuery: Another simple LINQ to XML sample query. This sample shows the minimal code necessary to write a LINQ to XML query
LinqToXmlDataBinding: Bind LINQ to XML code to WPF controls.
Advanced Samples
DynamicQuery: Code to create LINQ queries at run time.
Reflector: Use LINQ to right queries against the objects in your code using the Reflection APIs.
RSS: This sample acts as a tiny web server that aggregates several RSS feeds
SimpleLambdas: Several examples of how to write and use lambda expressions.
WebServiceLinqProvider: A sample showing how to create a LINQ provider to query Terraserver, a web service offering geographical data.
Addins and Visualizers
ExpressionTreeVisualizer: Create a visualization of an Expression Tree.
QueryVisualizer: Allows LINQ to SQL developers to see the SQL for their query, and also to see the results of the query in a grid.
PasteXmlAsLinq: A Visual Studio addin that automatically converts XML markup to LINQ to XML code. Note: Addins cannot be compiled or loaded within C# Express.
Libraries or Utilities
Data: Contains XML files and a modified copy of the Northwind database for use by several of the other samples.
ObjectDumper: A utility for writing the output from a LINQ query to the screen in text mode.
NorthwindMapping: Contains the ORM mapping created by the LINQ to SQL designer for the Northwind database that ships with these samples. It is used by DynamicQuery and WinFormsDataBinding.
Whitepapers: The following papers are stored in this directory in Word format:
LINQ Project Overview
LINQ to SQL Overview for C# and VB
Standard Query Operators
LINQ to XML Overview
C#语法例子包括:
AnonymousDelegates
Arrays
Attributes
CollectionClasses
COMInteropPart1
COMInteropPart2
CommandLine
ConditionalMethods
Delegates
Events
ExplicitInterface
Generics
HelloWorld
IndexedProperties
Indexers
Libraries
Nullable
OLEDB
OperatorOverloading
PartialTypes
Pinvoke
Properties
Security
Threading
Unsafe
Versioning
XMLdoc
Yield
UserConversions