DependencyService.Get<T>(DependencyFetchTarget) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
public static T Get<T> (Microsoft.Maui.Controls.DependencyFetchTarget fetchTarget = Microsoft.Maui.Controls.DependencyFetchTarget.GlobalInstance) where T : class;
static member Get : Microsoft.Maui.Controls.DependencyFetchTarget -> 'T (requires 'T : null)
Public Shared Function Get(Of T As Class) (Optional fetchTarget As DependencyFetchTarget = Microsoft.Maui.Controls.DependencyFetchTarget.GlobalInstance) As T
Type Parameters
- T
Parameters
- fetchTarget
- DependencyFetchTarget
Returns
T