XmlResolver.GetEntityAsync(Uri, String, Type) 方法

定義

以非同步的方式對應 URI 至包含實際資源的物件。

public:
 virtual System::Threading::Tasks::Task<System::Object ^> ^ GetEntityAsync(Uri ^ absoluteUri, System::String ^ role, Type ^ ofObjectToReturn);
public virtual System.Threading.Tasks.Task<object> GetEntityAsync (Uri absoluteUri, string? role, Type? ofObjectToReturn);
public virtual System.Threading.Tasks.Task<object> GetEntityAsync (Uri absoluteUri, string role, Type ofObjectToReturn);
abstract member GetEntityAsync : Uri * string * Type -> System.Threading.Tasks.Task<obj>
override this.GetEntityAsync : Uri * string * Type -> System.Threading.Tasks.Task<obj>
Public Overridable Function GetEntityAsync (absoluteUri As Uri, role As String, ofObjectToReturn As Type) As Task(Of Object)

參數

absoluteUri
Uri

ResolveUri(Uri, String) 傳回的 URI。

role
String

目前未使用。

ofObjectToReturn
Type

要傳回的物件類型。 目前的版本只傳回 Stream 物件。

傳回

Task<Object>

如果指定的類型並非資料流,則為資料流物件或為 null

備註

這是 的非同步版本 GetEntity ,具有相同的功能。 若要使用此方法,您必須將 Async 旗標設定為 true

適用於

另請參閱