Class DefaultActivitySourceFactory
- Namespace
- Arc4u.Diagnostics
- Assembly
- Arc4u.Diagnostics.dll
Default Arc4u implementation of the IActivitySourceFactory. Thread Safe implementation.
public class DefaultActivitySourceFactory : IActivitySourceFactory
- Inheritance
-
DefaultActivitySourceFactory
- Implements
- Inherited Members
Constructors
DefaultActivitySourceFactory()
Initializes a new instance of the DefaultActivitySourceFactory class with an empty cache of ActivitySource instances.
public DefaultActivitySourceFactory()
Methods
Get(string, string?)
Get and Create an ActivitySource based on the name and version.
public ActivitySource Get(string name, string? version = null)
Parameters
namestringThe name of the ActivitySource.
versionstringAn optinal parameter to add a version to an ActivitySource.
Returns
- ActivitySource
A specific instance of an ActivitySource.
Exceptions
- ArgumentNullException
nameis null, empty or white space.