Elmah.ServiceCenter.FindService C# (CSharp) Méthode

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
        public static object FindService(object context, Type serviceType)
        {
            if (serviceType == null) 
                throw new ArgumentNullException("serviceType");
            
            return GetServiceProvider(context).GetService(serviceType);
        }