NestedContainer.GetService(Type) 方法

定義

取得指定類型的服務物件(若可用)。

protected:
 override System::Object ^ GetService(Type ^ service);
protected override object GetService(Type service);
override this.GetService : Type -> obj
Protected Overrides Function GetService (service As Type) As Object

參數

service
Type

Type服務的取回。

傳回

一個 Object 實作所請求服務,或 null 當服務無法解決時。

備註

此方法會覆蓋該方法。Container.GetService 此實作僅解決 與 IContainer 服務的請求INestedContainer

適用於

另請參閱