contents
foreword
preface
acknowledgments
about this book
Part 1 Getting started
1 Introducing LINQ
1.1 What is LINQ?
1.2 Why do we need LINQ?
1.3 Design goals and origins of LINQ
1.4 First steps with LINQ to Objects: Querying collections
in memory
1.5 First steps with LINQ to XML: Querying XML documents
1.6 First steps with LINQ to SQL: Querying relational databases
1.7 Summary
2 C# and VB.NET language enhancements
2.1 Discovering the new language enhancements
2.2 Implicitly typed local variables
2.3 Object and collection initializers
2.4 Lambda expressions
2.5 Extension methods
2.6 Anonymous types
2.7 Summary
3 LINQ building blocks
3.1 How LINQ extends .NET
3.2 Introducing sequences
3.3 Introducing query operators
3.4 Introducing query expressions
3.5 Introducing expression trees
3.6 LINQ DLLs and namespaces
3.7 Summary
Part 2 Querying objects in memory
4 Getting familiar with LINQ to Objects
4.1 Introducing our running example
4.2 Using LINQ with in-memory collections
4.3 Using LINQ with ASP.NET and Windows Forms
4.4 Focus on major standard query operators
4.5 Creating views on an object graph in memory
4.6 Summary
5 Beyond basic in-memory queries
5.1 Common scenarios
5.2 Design patterns
5.3 Performance considerations
5.4 Summary
Part 3 Querying relational data
6 Getting started with LINQ to SQL
6.1 Jump into LINQ to SQL
6.2 Reading data with LINQ to SQL
6.3 Refining our queries
6.4 Working with object trees
6.5 When is my data loaded and why does it matter?
6.6 Updating data
6.7 Summary
7 Peeking under the covers of LINQ to SQL
7.1 Mapping objects to relational data
7.2 Translating query expressions to SQL
7.3 The entity life cycle
7.4 Summary
8 Advanced LINQ to SQL features
8.1 Handling simultaneous changes
8.2 Advanced database capabilities
8.3 Improving the business tier
8.4 A brief diversion into LINQ to Entities
8.5 Summary
Part 4 Manipulating XML
9 Introducing LINQ to XML
9.1 What is an XML API?
9.2 Why do we need another XML programming API?
9.3 LINQ to XML design principles
9.4 LINQ to XML class hierarchy
9.5 Working with XML using LINQ
9.6 Summary
10 Query and transform XML with LINQ to XML
10.1 LINQ to XML axis methods
10.2 Standard query operators
10.3 Querying LINQ to XML objects with XPath
10.4 Transforming XML
10.5 Summary
11 Common LINQ to XML scenarios
11.1 Building objects from XML
11.2 Creating XML from object graphs
11.3 Creating XML with data from a database
11.4 Filtering and mixing data from a database with XML data
11.5 Reading XML and updating a database
11.6 Transforming text files into XML
11.7 Summary
Part 5 LINQing it all together
12 Extending LINQ
12.1 Discovering LINQ’s extension mechanisms
12.2 Creating custom query operators
12.3 Custom implementations of the basic query operators
12.4 Querying a web service: LINQ to Amazon
12.5 IQueryable and IQueryProvider: LINQ to Amazon advanced edition
12.6 Summary
13 LINQ in every layer
13.1 Overview of the LinqBooks application
13.2 LINQ to SQL and the data access layer
13.3 Use of LINQ to XML
13.4 Use of LINQ to DataSet
13.5 Using LINQ to Objects
13.6 Extensibility
13.7 A look into the future
13.8 Summary
 
appendix: The standard query operators
resources
index
bonus chapter: Working with LINQ and DataSets (available online only from www.manning.com/LINQinAction)