Condividi tramite


Metodo DataServiceProviderMethods.OfType<TSource, TResult> (IQueryable<TSource>, ResourceType)

Filtra la query fornita in base all'oggetto ResourceType specificato.

Spazio dei nomi  System.Data.Services.Providers
Assembly:  Microsoft.Data.Services (in Microsoft.Data.Services.dll)

Sintassi

'Dichiarazione
Public Shared Function OfType(Of TSource, TResult) ( _
    query As IQueryable(Of TSource), _
    resourceType As ResourceType _
) As IQueryable(Of TResult)
'Utilizzo
Dim query As IQueryable(Of TSource)
Dim resourceType As ResourceType
Dim returnValue As IQueryable(Of TResult)

returnValue = DataServiceProviderMethods.OfType(query, _
    resourceType)
public static IQueryable<TResult> OfType<TSource, TResult>(
    IQueryable<TSource> query,
    ResourceType resourceType
)
public:
generic<typename TSource, typename TResult>
static IQueryable<TResult>^ OfType(
    IQueryable<TSource>^ query, 
    ResourceType^ resourceType
)
static member OfType : 
        query:IQueryable<'TSource> * 
        resourceType:ResourceType -> IQueryable<'TResult> 
JScript non supporta metodi e tipi generici.

Parametri di tipo

  • TSource
    Tipo dell'istanza di IQueryable<T> fornita come parametro query.
  • TResult
    Tipo che rappresenta il tipo di risorsa fornito come parametro resourceType.

Parametri

Valore restituito

Tipo: System.Linq.IQueryable<TResult>
Restituisce un'istanza di IQueryable<T> filtrata in base all'oggetto resourceType fornito.

Vedere anche

Riferimento

DataServiceProviderMethods Classe

Overload OfType

Spazio dei nomi System.Data.Services.Providers