GetService<T>()
Resolves a service of type T by running its factory.
Declaration
public static T GetService<T>()Returns
| Type | Description |
|---|---|
| T | The service returned by the factory, or the default value of |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the service. |
Exceptions
| Type | Condition |
|---|---|
| InvalidCastException | The factory returned an object that is not assignable to |