Class LogListener
- Namespace
- StockSharp.Logging
- Assembly
- StockSharp.Logging.dll
The base class that monitors the event Log and saves to some storage.
public abstract class LogListener : Disposable, ILogListener, IPersistable, IDisposable
- Inheritance
-
LogListener
- Implements
-
IPersistable
- Derived
- Extension Methods
Constructors
LogListener()
Initialize LogListener.
protected LogListener()
Properties
CanSave
Can save listener.
public virtual bool CanSave { get; }
Property Value
DateFormat
Date format. By default yyyy/MM/dd.
public string DateFormat { get; set; }
Property Value
Filters
Messages filters that specify which messages should be handled.
public IList<Func<LogMessage, bool>> Filters { get; }
Property Value
- IList<Func<LogMessage, bool>>
TimeFormat
Time format. By default HH:mm:ss.fff.
public string TimeFormat { get; set; }
Property Value
Methods
Load(SettingsStorage)
Load settings.
public virtual void Load(SettingsStorage storage)
Parameters
storage
SettingsStorageSettings storage.
OnWriteMessage(LogMessage)
To record a message.
protected virtual void OnWriteMessage(LogMessage message)
Parameters
message
LogMessageA debug message.
OnWriteMessages(IEnumerable<LogMessage>)
To record messages.
protected virtual void OnWriteMessages(IEnumerable<LogMessage> messages)
Parameters
messages
IEnumerable<LogMessage>Debug messages.
Save(SettingsStorage)
Save settings.
public virtual void Save(SettingsStorage storage)
Parameters
storage
SettingsStorageSettings storage.
WriteMessages(IEnumerable<LogMessage>)
To record messages.
public void WriteMessages(IEnumerable<LogMessage> messages)
Parameters
messages
IEnumerable<LogMessage>Debug messages.