ServiceManager.GetService Yöntem

Tanım

Aşırı Yüklemeler

GetService(Type)

İstenen hizmeti alır. Bu yöntem, hizmet bulunamadığında döndürür null .

GetService<TServiceType>()

İstenen hizmeti alır. Bu yöntem, hizmet bulunamadığında döndürür null .

GetService(Type)

İstenen hizmeti alır. Bu yöntem, hizmet bulunamadığında döndürür null .

public:
 abstract System::Object ^ GetService(Type ^ serviceType);
public abstract object GetService (Type serviceType);
abstract member GetService : Type -> obj
Public MustOverride Function GetService (serviceType As Type) As Object

Parametreler

serviceType
Type

Alınacak hizmet türü.

Döndürülenler

Hizmetin bir örneği olan veya null hizmet yayımlanmamışsa değerini döndürürObject.

Uygulamalar

Özel durumlar

serviceType, null değeridir.

Şunlara uygulanır

GetService<TServiceType>()

İstenen hizmeti alır. Bu yöntem, hizmet bulunamadığında döndürür null .

public:
generic <typename TServiceType>
 TServiceType GetService();
public TServiceType GetService<TServiceType> ();
member this.GetService : unit -> 'ServiceType
Public Function GetService(Of TServiceType) () As TServiceType

Tür Parametreleri

TServiceType

Alınacak hizmet türü.

Döndürülenler

TServiceType

Hizmetin bir örneği olan veya null hizmetin yayımlanmamış olduğu genel bir tür.

Şunlara uygulanır