Table of Contents

Class MutableDependencyResolverExtensions

Namespace
Splat.Serilog
Assembly
Splat.Serilog.dll

Provides extension methods for registering Serilog as the logging implementation within Splat using the Wrapping Full Logger.

public static class MutableDependencyResolverExtensions
Inheritance
MutableDependencyResolverExtensions

Remarks

These extension methods allow you to configure Splat to use Serilog for logging by registering the appropriate logger implementation with an IMutableDependencyResolver. Serilog should be configured before invoking these methods. These helpers are intended to simplify integration of Serilog with Splat's logging infrastructure.

Methods

UseSerilogFullLogger(IMutableDependencyResolver)

Simple helper to initialize Serilog within Splat with the Wrapping Full Logger.

public static void UseSerilogFullLogger(this IMutableDependencyResolver instance)

Parameters

instance IMutableDependencyResolver

An instance of Mutable Dependency Resolver.

Examples

AppLocator.CurrentMutable.UseSerilogWithWrappingFullLogger();

Remarks

You should configure Serilog prior to calling this method.

UseSerilogFullLogger(IMutableDependencyResolver, ILogger)

Simple helper to initialize Serilog within Splat with the Wrapping Full Logger.

public static void UseSerilogFullLogger(this IMutableDependencyResolver instance, ILogger actualLogger)

Parameters

instance IMutableDependencyResolver

An instance of Mutable Dependency Resolver.

actualLogger ILogger

The serilog logger to register.

Examples

AppLocator.CurrentMutable.UseSerilogWithWrappingFullLogger();

Remarks

You should configure Serilog prior to calling this method.