JSObjectReferenceExtensions.InvokeVoidAsync 方法

定義

多載

InvokeVoidAsync(IJSObjectReference, String, Object[])

以非同步方式叫用指定的 JavaScript 函式。

InvokeVoidAsync(IJSObjectReference, String, CancellationToken, Object[])

以非同步方式叫用指定的 JavaScript 函式。

InvokeVoidAsync(IJSObjectReference, String, TimeSpan, Object[])

以非同步方式叫用指定的 JavaScript 函式。

InvokeVoidAsync(IJSObjectReference, String, Object[])

以非同步方式叫用指定的 JavaScript 函式。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::ValueTask InvokeVoidAsync(Microsoft::JSInterop::IJSObjectReference ^ jsObjectReference, System::String ^ identifier, ... cli::array <System::Object ^> ^ args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, params object?[] args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, params object?[]? args);
static member InvokeVoidAsync : Microsoft.JSInterop.IJSObjectReference * string * obj[] -> System.Threading.Tasks.ValueTask
<Extension()>
Public Function InvokeVoidAsync (jsObjectReference As IJSObjectReference, identifier As String, ParamArray args As Object()) As ValueTask

參數

jsObjectReference
IJSObjectReference

IJSObjectReference

identifier
String

要叫用之函式的識別碼。 例如,值 "someScope.someFunction" 會在目標實例上叫用 函 someScope.someFunction 式。

args
Object[]

JSON 可序列化引數。

傳回

ValueTask 表示非同步調用作業。

適用於

InvokeVoidAsync(IJSObjectReference, String, CancellationToken, Object[])

以非同步方式叫用指定的 JavaScript 函式。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::ValueTask InvokeVoidAsync(Microsoft::JSInterop::IJSObjectReference ^ jsObjectReference, System::String ^ identifier, System::Threading::CancellationToken cancellationToken, ... cli::array <System::Object ^> ^ args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, System.Threading.CancellationToken cancellationToken, params object?[] args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, System.Threading.CancellationToken cancellationToken, params object?[]? args);
static member InvokeVoidAsync : Microsoft.JSInterop.IJSObjectReference * string * System.Threading.CancellationToken * obj[] -> System.Threading.Tasks.ValueTask
<Extension()>
Public Function InvokeVoidAsync (jsObjectReference As IJSObjectReference, identifier As String, cancellationToken As CancellationToken, ParamArray args As Object()) As ValueTask

參數

jsObjectReference
IJSObjectReference

IJSObjectReference

identifier
String

要叫用之函式的識別碼。 例如,值 "someScope.someFunction" 會在目標實例上叫用 函 someScope.someFunction 式。

cancellationToken
CancellationToken

表示取消作業取消的解除標記。 指定此參數會覆寫任何預設取消,例如因為套用逾時 (DefaultAsyncTimeout) 。

args
Object[]

JSON 可序列化引數。

傳回

ValueTask 表示非同步調用作業。

適用於

InvokeVoidAsync(IJSObjectReference, String, TimeSpan, Object[])

以非同步方式叫用指定的 JavaScript 函式。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::ValueTask InvokeVoidAsync(Microsoft::JSInterop::IJSObjectReference ^ jsObjectReference, System::String ^ identifier, TimeSpan timeout, ... cli::array <System::Object ^> ^ args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, TimeSpan timeout, params object?[] args);
public static System.Threading.Tasks.ValueTask InvokeVoidAsync (this Microsoft.JSInterop.IJSObjectReference jsObjectReference, string identifier, TimeSpan timeout, params object?[]? args);
static member InvokeVoidAsync : Microsoft.JSInterop.IJSObjectReference * string * TimeSpan * obj[] -> System.Threading.Tasks.ValueTask
<Extension()>
Public Function InvokeVoidAsync (jsObjectReference As IJSObjectReference, identifier As String, timeout As TimeSpan, ParamArray args As Object()) As ValueTask

參數

jsObjectReference
IJSObjectReference

IJSObjectReference

identifier
String

要叫用之函式的識別碼。 例如,值 "someScope.someFunction" 會在目標實例上叫用 函 someScope.someFunction 式。

timeout
TimeSpan

要取消非同步作業的持續時間。 覆寫預設逾時 (DefaultAsyncTimeout) 。

args
Object[]

JSON 可序列化引數。

傳回

ValueTask 表示非同步調用作業。

適用於