Skip to content

5ea74454 31ad f4d0 f19d ee9a10af3765

Axel Kesseler edited this page Mar 1, 2023 · 8 revisions

StreamLoggerSettings Class

The class to provide settings for all of the stream logging writers.

Inheritance Hierarchy

System.Object
  Plexdata.LogWriter.Settings.LoggerSettings
    Plexdata.LogWriter.Settings.StreamLoggerSettings
Namespace: Plexdata.LogWriter.Settings
Assembly: Plexdata.LogWriter.Stream (in Plexdata.LogWriter.Stream.dll) Version: 1.0.7.1

Syntax

C#

public class StreamLoggerSettings : LoggerSettings, 
	IStreamLoggerSettings, ILoggerSettings, INotifyPropertyChanged

The StreamLoggerSettings type exposes the following members.

Constructors

 

Name Description
Private methodStatic member StreamLoggerSettings The static class constructor.
Public method StreamLoggerSettings() The standard class constructor.
Public method StreamLoggerSettings(Stream) The extended constructor that initializes all properties with its default values, but takes the stream instance.
Public method StreamLoggerSettings(ILoggerSettingsSection) The extended constructor that initializes all properties from provided configuration instance.
Public method StreamLoggerSettings(ILoggerSettingsSection, Stream) The extended constructor that initializes all properties from provided configuration instance. Property Stream is initialized from parameter stream.
  Back to Top

Properties

 

Name Description
Public property Culture Gets and sets the culture information to be used. (Inherited from LoggerSettings.)
Public property Encoding Gets or sets the used file encoding.
Public property FullName Determines whether the full name is used in messages or not. (Inherited from LoggerSettings.)
Public property LogLevel Gets and sets the logging level to be used. (Inherited from LoggerSettings.)
Public property LogTime Gets and sets the type of time to be used. (Inherited from LoggerSettings.)
Public property LogType Gets and sets the output format to be used. (Inherited from LoggerSettings.)
Public property PartSplit Gets and sets the character to separate each of the message parts. (Inherited from LoggerSettings.)
Public property ShowKey Determines whether the message key is shown or not. (Inherited from LoggerSettings.)
Public property ShowTime Determines whether the message timestamp is shown or not. (Inherited from LoggerSettings.)
Public property Stream Gets and sets the stream to be used as message sink.
Public property TimeFormat Gets and sets the time format to be used. (Inherited from LoggerSettings.)
  Back to Top

Methods

 

Name Description
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Protected method GetSectionValues Gets the values from section for provided key. (Inherited from LoggerSettings.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method GetValue(TType) Gets the type-safe value of provided value. (Inherited from LoggerSettings.)
Private method IsValidCultureName Checks if value is a valid culture name. (Inherited from LoggerSettings.)
Protected method LoadSettings The method loads all settings from provided configuration and initializes all properties accordingly. (Overrides LoggerSettings.LoadSettings(ILoggerSettingsSection).)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Protected method RaisePropertyChanged Informs listeners about property changes. (Inherited from LoggerSettings.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)
  Back to Top

Events

 

Name Description
Public event PropertyChanged Occurs when a property value changes. (Inherited from LoggerSettings.)
  Back to Top

Fields

 

Name Description
Private field culture This field represents currently assigned culture. (Inherited from LoggerSettings.)
Private fieldStatic member DefaultEncoding The default encoding value.
Private field encoding This field holds the chosen encoding.
Private field fullName This field represents current state of full name usage. (Inherited from LoggerSettings.)
Private field logLevel This field represents current logging level. (Inherited from LoggerSettings.)
Private field logTime This field represents current logging time. (Inherited from LoggerSettings.)
Private field logType This field represents current logging type. (Inherited from LoggerSettings.)
Private field partSplit This field represents current part split character. (Inherited from LoggerSettings.)
Private field showKey This field represents current state of key visibility. (Inherited from LoggerSettings.)
Private field showTime This field represents current state of time stamp visibility. (Inherited from LoggerSettings.)
Private field stream This field holds the used stream.
Private field timeFormat This field represents current time stamp format. (Inherited from LoggerSettings.)
  Back to Top

Remarks

This class allows a configuration of classes derived from stream logger interfaces. But keep in mind, the availability of particular setting items depends of which of the available stream loggers is actually used.

Attention, logging type JSON is used as the default logging type.

See Also

Reference

Plexdata.LogWriter.Settings Namespace

Clone this wiki locally