IdeaBlade.EntityModel Assembly > IdeaBlade.EntityModel Namespace > EntityQueryExtensions Class > Select Method : Select<TSource>(IEntityQuery<TSource>,IProjectionSelector) Method |
'Declaration
<ExtensionAttribute()> Public Overloads Shared Function Select(Of TSource)( _ ByVal source As IEntityQuery(Of TSource), _ ByVal selector As IProjectionSelector _ ) As ITypedEntityQuery
'Usage
Dim source As IEntityQuery(Of TSource) Dim selector As IProjectionSelector Dim value As ITypedEntityQuery value = EntityQueryExtensions.Select(Of TSource)(source, selector)
[Extension()] public static ITypedEntityQuery Select<TSource>( IEntityQuery<TSource> source, IProjectionSelector selector )
var mgr = new DomainModelEntityManager(); var rootQuery = mgr.Customers; var ps1 = new ProjectionSelector("CompanyName"); var ps2 = new ProjectionSelector("ContactName"); var pps = ps1.Combine(ps2); var query = rootQuery.Select(pps); var results = query.Execute();
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2