Class DiagnosticObserver
- Namespace
- Steeltoe.Common.Diagnostics
- Assembly
- Steeltoe.Management.Abstractions.dll
public abstract class DiagnosticObserver : IDiagnosticObserver, IObserver<KeyValuePair<string, object>>
- Inheritance
-
DiagnosticObserver
- Implements
- Derived
- Inherited Members
Constructors
DiagnosticObserver(string, string, ILogger)
protected DiagnosticObserver(string name, string listenerName, ILogger logger = null)
Parameters
Properties
ListenerName
public string ListenerName { get; }
Property Value
Logger
protected ILogger Logger { get; }
Property Value
ObserverName
public string ObserverName { get; }
Property Value
Subscription
protected IDisposable Subscription { get; set; }
Property Value
Methods
Dispose()
public void Dispose()
OnCompleted()
Notifies the observer that the provider has finished sending push-based notifications.
public virtual void OnCompleted()
OnError(Exception)
Notifies the observer that the provider has experienced an error condition.
public virtual void OnError(Exception error)
Parameters
errorExceptionAn object that provides additional information about the error.
OnNext(KeyValuePair<string, object>)
Provides the observer with new data.
public virtual void OnNext(KeyValuePair<string, object> @event)
Parameters
eventKeyValuePair<string, object>
ProcessEvent(string, object)
public abstract void ProcessEvent(string @event, object arg)
Parameters
Subscribe(DiagnosticListener)
public void Subscribe(DiagnosticListener listener)
Parameters
listenerDiagnosticListener