ElementHandlerExtensions.GetRequiredService 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
GetRequiredService<T>(IElementHandler) | |
GetRequiredService<T>(IElementHandler, Type) |
GetRequiredService<T>(IElementHandler)
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static T GetRequiredService(Microsoft::Maui::IElementHandler ^ handler);
public static T GetRequiredService<T> (this Microsoft.Maui.IElementHandler handler);
static member GetRequiredService : Microsoft.Maui.IElementHandler -> 'T
<Extension()>
Public Function GetRequiredService(Of T) (handler As IElementHandler) As T
類型參數
- T
參數
- handler
- IElementHandler
傳回
T
適用於
GetRequiredService<T>(IElementHandler, Type)
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static T GetRequiredService(Microsoft::Maui::IElementHandler ^ handler, Type ^ type);
public static T GetRequiredService<T> (this Microsoft.Maui.IElementHandler handler, Type type);
static member GetRequiredService : Microsoft.Maui.IElementHandler * Type -> 'T
<Extension()>
Public Function GetRequiredService(Of T) (handler As IElementHandler, type As Type) As T
類型參數
- T
參數
- handler
- IElementHandler
- type
- Type
傳回
T