C# Class Elmah.ServiceCenter

Central point for locating arbitrary services.
Afficher le fichier Open project: elmah/Elmah Class Usage Examples

Méthodes publiques

Свойство Type Description
Default ServiceProviderQueryHandler

Méthodes publiques

Méthode Description
FindService ( object context, Type serviceType ) : object

Attempts to locate a service of a given type based on a given context. If the service is not available, a null reference is returned.

GetService ( object context, Type serviceType ) : object

Gets a service of a given type based on a given context. If the service is not available, an exception is thrown.

GetServiceProvider ( object context ) : IServiceProvider

Gets an IServiceProvider object based on a supplied context and which can be used to request further services.

Private Methods

Méthode Description
CreateServiceContainer ( object context ) : IServiceProvider
ServiceCenter ( ) : System

Method Details

FindService() public static méthode

Attempts to locate a service of a given type based on a given context. If the service is not available, a null reference is returned.
public static FindService ( object context, Type serviceType ) : object
context object
serviceType System.Type
Résultat object

GetService() public static méthode

Gets a service of a given type based on a given context. If the service is not available, an exception is thrown.
public static GetService ( object context, Type serviceType ) : object
context object
serviceType System.Type
Résultat object

GetServiceProvider() public static méthode

Gets an IServiceProvider object based on a supplied context and which can be used to request further services.
public static GetServiceProvider ( object context ) : IServiceProvider
context object
Résultat IServiceProvider

Property Details

Default public_oe static_oe property

The default and factory-supplied implementation of ServiceProviderQueryHandler.
public static ServiceProviderQueryHandler Default
Résultat ServiceProviderQueryHandler