NullLoggerFactory Class

Definition

An ILoggerFactory used to create an instance of NullLogger that logs nothing.

public ref class NullLoggerFactory : IDisposable, Microsoft::Extensions::Logging::ILoggerFactory
public class NullLoggerFactory : IDisposable, Microsoft.Extensions.Logging.ILoggerFactory
type NullLoggerFactory = class
    interface ILoggerFactory
    interface IDisposable
Public Class NullLoggerFactory
Implements IDisposable, ILoggerFactory
Inheritance
NullLoggerFactory
Implements

Constructors

Name Description
NullLoggerFactory()

Creates a new NullLoggerFactory instance.

Fields

Name Description
Instance

Returns the shared instance of NullLoggerFactory.

Methods

Name Description
AddProvider(ILoggerProvider)

Adds an ILoggerProvider to the logging system.

CreateLogger(String)

Creates a new ILogger instance.

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
ToString()

Returns a string that represents the current object.

(Inherited from Object)

Extension Methods

Name Description
CreateLogger(ILoggerFactory, Type)

Creates a new ILogger instance using the full name of the given type.

CreateLogger<T>(ILoggerFactory)

Creates a new ILogger instance using the full name of the given type.

Applies to