ServiceContainer.GetService(Type) 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.
Gets the requested service.
public:
virtual System::Object ^ GetService(Type ^ serviceType);
public virtual object GetService (Type serviceType);
public virtual object? GetService (Type serviceType);
public object GetService (Type serviceType);
abstract member GetService : Type -> obj
override this.GetService : Type -> obj
Public Overridable Function GetService (serviceType As Type) As Object
Public Function GetService (serviceType As Type) As Object
Parameters
- serviceType
- Type
The type of service to retrieve.
Returns
An instance of the service if it could be found, or null
if it could not be found.
Implements
Applies to
See also
Dolgozzon együtt velünk a GitHubon
A tartalom forrása a GitHubon található, ahol létrehozhat és áttekinthet problémákat és lekéréses kérelmeket is. További információért tekintse meg a közreműködői útmutatónkat.