Table of Contents

Class ReadingsRegistryExtensions

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

Extension methods for IReadingsRegistry.

public static class ReadingsRegistryExtensions
Inheritance
ReadingsRegistryExtensions
Inherited Members

Methods

GetLatestReadingValueAsync(IReadingsRegistry, string, CancellationToken)

Gets the latest value from a reading data source.

public static Task<TimestampedReadingValue> GetLatestReadingValueAsync(this IReadingsRegistry readingsRegistry, string readingName, CancellationToken cancellationToken = default)

Parameters

readingsRegistry IReadingsRegistry

The IReadingsRegistry.

readingName string

The reading name.

cancellationToken CancellationToken

A token that can request canceling waiting on the reading value.

Returns

Task<TimestampedReadingValue>

A task that represents the asynchronous operation. The value of its Result property contains the reading value.

Exceptions

ArgumentNullException

readingsRegistry is null.

ArgumentNullException

readingName is null.

KeyNotFoundException

readingName does not specify a known reading.