Class LogService
Allows logger creation like ILoggerFactory but without the obsolete 1.0-style AddProvider method
public class LogService
- Inheritance
-
LogService
- Inherited Members
Constructors
LogService(ILoggerFactory)
public LogService(ILoggerFactory loggerFactory)
Parameters
loggerFactoryILoggerFactory
Methods
CreateLogger(string)
Create an ILogger for a named category (which should usually be a type name).
public ILogger CreateLogger(string categoryName)
Parameters
categoryNamestring
Returns
CreateLogger(Type)
Create an ILogger for some instance of a type t, using the full name of the type as its category.
public ILogger CreateLogger(Type t)
Parameters
tType
Returns
CreateLogger<T>()
Create an ILogger for some instance of a type T, using the full name of the type as its category.
public ILogger<T> CreateLogger<T>()
Returns
- ILogger<T>
Type Parameters
T