Extensions GetService TService  Method TIBCO Spotfire 6.0 API Reference
Convenience generic extension method that calls GetService(Type) and casts the result.

Namespace: Spotfire.Dxp.Framework.Services
Assembly: Spotfire.Dxp.Framework (in Spotfire.Dxp.Framework.dll) Version: 13.19.7018.3940 (13.19.7018.3940)
Syntax

public static TService GetService<TService>(
	this IServiceProvider provider
)
where TService : class

Parameters

provider
Type: System IServiceProvider
The service provider instance.
Type Parameters

TService
The type of service object to get.

Return Value

Type: TService
A service object of type TService -or- null if there is no service object of type TService.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IServiceProvider. When you use instance method syntax to call this method, omit the first parameter. For more information, see OnlineExtension Methods (Visual Basic) or OnlineExtension Methods (C# Programming Guide).
See Also