DataContext.CreateMethodCallQuery<TResult>(Object, MethodInfo, Object[]) 方法

定義

執行與指定之 .NET 方法關聯的資料表值資料庫函式。Executes the table-valued database function associated with the specified .NET method.

protected public:
generic <typename TResult>
 System::Linq::IQueryable<TResult> ^ CreateMethodCallQuery(System::Object ^ instance, System::Reflection::MethodInfo ^ methodInfo, ... cli::array <System::Object ^> ^ parameters);
protected internal System.Linq.IQueryable<TResult> CreateMethodCallQuery<TResult> (object instance, System.Reflection.MethodInfo methodInfo, params object[] parameters);
member this.CreateMethodCallQuery : obj * System.Reflection.MethodInfo * obj[] -> System.Linq.IQueryable<'Result>

類型參數

TResult

所傳回集合中項目的型別。The type of the elements in the returned collection.

參數

instance
Object

方法引動過程的執行個體 (目前物件)。The instance of the method invocation (the current object).

methodInfo
MethodInfo

指出對應到資料庫方法之 .NET 方法的 MethodInfoThe MethodInfo that identifies the .NET method that corresponds to a database method.

parameters
Object[]

要傳遞至命令的參數陣列。The array of parameters to be passed to the command.

傳回

IQueryable<TResult>

資料庫查詢所傳回結果值的集合。A collection of resultant values returned by the database query.

備註

方法CreateMethodCallQuery會用於自動產生的程式碼中,並作為資料庫函式的 proxy。The CreateMethodCallQuery method is used in automatically generated code and acts as a proxy to database functions.

適用於