GetService Method (Type)
Retrives the requested service. This method returns null if the service could not be located.
Namespace: Microsoft.Data.Tools.Design.Core.Context
Assembly: Microsoft.Data.Tools.Design.Core (in Microsoft.Data.Tools.Design.Core.dll)
Syntax
'Declaration
Public MustOverride Function GetService ( _
serviceType As Type _
) As Object
'Usage
Dim instance As ServiceCollection
Dim serviceType As Type
Dim returnValue As Object
returnValue = instance.GetService(serviceType)
public abstract Object GetService(
Type serviceType
)
public:
virtual Object^ GetService(
Type^ serviceType
) abstract
abstract GetService :
serviceType:Type -> Object
public abstract function GetService(
serviceType : Type
) : Object
Parameters
- serviceType
Type: System..::..Type
The type of service to retrieve.
Return Value
Type: System..::..Object
An instance of the service, or null if the service has not been published.
Implements
IServiceProvider..::..GetService(Type)
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | If serviceType is null. |