Академический Документы
Профессиональный Документы
Культура Документы
Octavio Hernndez
Mentoring Team Leader Plain Concepts
Introduccin a LINQ Proveedores predeterminados Extendiendo LINQ a nuevos tipos de datos y libreras Recomendaciones de uso LINQ despus de .NET 3.5 Demos
Mecanismo uniforme y extensible para consultar fuentes de datos de diferentes tipos: las expresiones de consulta. Sintaxis basada en nuevas palabras reservadas contextuales. Semntica enchufable: los lenguajes no definen la semntica de las nuevas palabras reservadas, sino nicamente un conjunto de reglas para reescribir esas expresiones como cascadas de llamadas a mtodos.
var delMadrid = from f in DatosFutbol.Futbolistas where f.CodigoClub == RMA" select new { f.Nombre, f.Edad };
var delMadrid = DatosFutbol.Futbolistas .Where(f => f.CodigoClub == RMA") .Select(f => new { f.Nombre, f.Edad });
Fuentes de consultas
Los datos provienen de cierta fuente, que implementa IEnumerable<T>.
Encuentros
Cuantificadores Particin Conjuntuales Un elemento Agregados Conversin
Join, GroupJoin
Any, All Take, Skip, TakeWhile, SkipWhile Distinct, Union, Intersect, Except First, Last, Single, ElementAt Count, Sum, Min, Max, Average ToArray, ToList, ToDictionary
Conversin de elementos
OfType<T>, Cast<T>
Composicionales, jerrquicas
Anidamiento arbitrario. Posibilidad de aplicar operadores adicionales.
Declarativas y no imperativas
Diga qu usted desea obtener, no cmo. El cmo va por el proveedor.
Ejecucin diferida
Las consultas se ejecutan solo a medida que sus resultados se solicitan.
Tecnologa
Ensamblado System.Core.dll
LINQ to Objects
LINQ System.Xml.Linq.dll System.Xml.Linq to Basados XML en IEnumerable<T> Basados en IQueryable<T> LINQ to DataSet System.Data.DataSetExtensions.dll System.Data.Linq.dll System.Data.Entity.dll System.Data System.Data.Linq System.Data.Objects y otros
LINQ to SQL
LINQ to Entities
Silverlight 2.0
.NET 3.5
.NET 3.5 CF
{ LINQ en profundidad }
C# 3.0
VB 9.0
Otros
Proveedores LINQ
Basados en IEnumerable<T> LINQ to Objects LINQ to XML
<libro> <titulo/> <autor/> <precio/> </libro>
Objetos
XML
BB.DD.
Basados en IEnumerable<T>
Implementacin Iteradores
LINQ to Objects LINQ to XML LINQ to DataSet
Basados en IQueryable<T>
Anlisis de rboles de expresiones
Proveedores
Mis ejemplos
{ LINQ en profundidad }
Proveedores a medida
Aprenda:
A escribir consultas con y sin la sintaxis. Las nuevas caractersticas de C# 3.0 Los detalles de la traduccin de la sintaxis en llamadas a operadores y cmo funcionan stos.
Parallel LINQ
Pasa partes de una consulta a diferentes ncleos/procesadores.
LINQ 2.0
LINQ es un mecanismo uniforme y extensible para consultar fuentes de datos de diferentes tipos LINQ cambiar la forma en que escribimos cdigo.
Ms declarativo Muchos menos bucles a la vista. Cdigo ms fcil de leer y mantener.
http://msdn.microsoft.com/vcsharp/
http://www.krasispress.com/
Revista dotNetMana
http://www.dotnetmania.com/
Entra
2007 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
Sistemas Externos
Capa de Datos
Lgica de Negocio
Presentacin
Modelo Conceptual (EDM) Entidades Relaciones