Table of Contents

Class MqttNetEventLogger

Namespace
MQTTnet.Diagnostics
Assembly
MQTTnet.dll

This logger fires an event when a new message was published.

public sealed class MqttNetEventLogger : IMqttNetLogger
Inheritance
MqttNetEventLogger
Implements
Inherited Members
Extension Methods

Constructors

MqttNetEventLogger(string)

public MqttNetEventLogger(string logId = null)

Parameters

logId string

Properties

IsEnabled

public bool IsEnabled { get; }

Property Value

bool

LogId

public string LogId { get; }

Property Value

string

Methods

Publish(MqttNetLogLevel, string, string, object[], Exception)

public void Publish(MqttNetLogLevel level, string source, string message, object[] parameters, Exception exception)

Parameters

level MqttNetLogLevel
source string
message string
parameters object[]
exception Exception

Events

LogMessagePublished

public event EventHandler<MqttNetLogMessagePublishedEventArgs> LogMessagePublished

Event Type

EventHandler<MqttNetLogMessagePublishedEventArgs>