Table of Contents

Class ReadingDataSource

Namespace
Acuit.Pinpoint.IO.Testing
Assembly
Acuit.Pinpoint.IO.Testing.Abstractions.dll

A reading data source.

public class ReadingDataSource : IReadingDataSource, IDataSource
Inheritance
ReadingDataSource
Implements
Inherited Members

Constructors

ReadingDataSource(IObservable<TimestampedReadingValue>, IReadingDescriptor)

Initializes a new instance of the ReadingDataSource class.

public ReadingDataSource(IObservable<TimestampedReadingValue> dataObservable, IReadingDescriptor descriptor)

Parameters

dataObservable IObservable<TimestampedReadingValue>

The IObservable<T> that produces data values.

descriptor IReadingDescriptor

The reading descriptor.

Properties

DataObservable

Gets the IObservable<T> that produces data values.

public IObservable<TimestampedReadingValue> DataObservable { get; }

Property Value

IObservable<TimestampedReadingValue>

Remarks

Subscriptions to reading observables will receive the last known reading value followed by any subsequent changes. Implementations can use System.Reactive.Subjects.BehaviorSubject<T> to produce this behavior.

A subscription to a reading observable will complete when the the source provider is unregistered.

Descriptor

Gets the reading descriptor.

public IReadingDescriptor Descriptor { get; }

Property Value

IReadingDescriptor

DisplayName

Gets the optional human-readable name of the data source (e.g., a reading name), or null if there is none.

public string DisplayName { get; }

Property Value

string

Remarks

This should be in title case (for example, "Gas Pressure").