Show / Hide Table of Contents

    Class GraphLoggerWrapper

    The ILogger wrapper for IGraphLogger.

    Inheritance
    Object
    GraphLoggerWrapper
    Implements
    ILogger
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Microsoft.Graph.Communications.Common.Telemetry
    Assembly: Microsoft.Graph.Communications.Common.dll
    Syntax
    public class GraphLoggerWrapper : ILogger

    Constructors

    GraphLoggerWrapper(IGraphLogger, String, Guid, LogEventType, IEnumerable<Object>)

    Initializes a new instance of the GraphLoggerWrapper class.

    Declaration
    public GraphLoggerWrapper(IGraphLogger graphLogger, string component = null, Guid correlationId = default(Guid), LogEventType eventType = LogEventType.Trace, IEnumerable<object> properties = null)
    Parameters
    Type Name Description
    IGraphLogger graphLogger

    Graph logger instance

    String component

    The component in which log is created

    Guid correlationId

    The correlation identifier.

    LogEventType eventType

    Log event type

    IEnumerable<Object> properties

    Extra properties for the log event

    Methods

    BeginScope<TState>(TState)

    Declaration
    public IDisposable BeginScope<TState>(TState state)
    Parameters
    Type Name Description
    TState state
    Returns
    Type Description
    IDisposable
    Type Parameters
    Name Description
    TState

    IsEnabled(LogLevel)

    Declaration
    public bool IsEnabled(LogLevel logLevel)
    Parameters
    Type Name Description
    LogLevel logLevel
    Returns
    Type Description
    Boolean

    Log<TState>(LogLevel, EventId, TState, Exception, Func<TState, Exception, String>)

    Declaration
    public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func<TState, Exception, string> formatter)
    Parameters
    Type Name Description
    LogLevel logLevel
    EventId eventId
    TState state
    Exception exception
    Func<TState, Exception, String> formatter
    Type Parameters
    Name Description
    TState

    Implements

    Microsoft.Extensions.Logging.ILogger

    Extension Methods

    AdditionalDataExtensions.SetInAdditionalData(Object, String, Object)
    Extensions.Pin(Object)
    Extensions.ChangeType(Object, Type)
    Extensions.ChangeType<T>(Object)
    Extensions.TryDispose(Object, IGraphLogger)
    ReflectionUtils.GetPropertyUsingReflection(Object, String)
    ReflectionUtils.SetPropertyUsingReflection(Object, String, Object)
    Validator.IsNull(Object, String, String)
    Validator.NotNull<T>(T, String, String)
    Validator.Equals<T>(T, T, String, String)
    Validator.Equals<T, TE>(T, T, String)
    Validator.NotEquals<T>(T, T, String, String)
    Back to top Copyright (c) Microsoft Corporation. All rights reserved.