Class TraceSources
- Namespace
- Songhay.Diagnostics
- Assembly
- SonghayCore.dll
Singleton wrapper for TraceSource
public class TraceSources
- Inheritance
-
TraceSources
- Inherited Members
- Extension Methods
Remarks
Based on Fonlow.Diagnostics by Zijian Huang [https://github.com/zijianhuang/Fonlow.Diagnostics] Also see “Use TraceSource Efficiently” [http://www.codeproject.com/Tips/1071853/Use-TraceSource-Efficiently]
Fields
DefaultTraceSourceName
The conventional TraceSource name.
public const string DefaultTraceSourceName = "rx-trace"
Field Value
Properties
ConfiguredTraceSourceName
The configured trace source name
public static string? ConfiguredTraceSourceName { get; set; }
Property Value
Instance
Gets the instance.
public static TraceSources Instance { get; }
Property Value
IsConfiguredTraceSourceNameLoaded
The is configured trace source name loaded?
public static bool IsConfiguredTraceSourceNameLoaded { get; }
Property Value
this[string?]
Gets the TraceSource with the specified name.
public TraceSource? this[string? name] { get; }
Parameters
name
stringThe name.
Property Value
Methods
GetTraceSource(string?)
Gets the trace source.
public TraceSource? GetTraceSource(string? name)
Parameters
name
stringThe name.
Returns
GetTraceSourceFromConfiguredName()
Gets the name of the trace source from configuration.
public TraceSource? GetTraceSourceFromConfiguredName()
Returns
Remarks
When the trace source name is not configured then DefaultTraceSourceName is used.