Class DeviceHeartbeat
public sealed class DeviceHeartbeat : IDeviceHeartbeat, IDisposable
- Inheritance
-
DeviceHeartbeat
- Implements
- Inherited Members
Constructors
DeviceHeartbeat(ILogger<DeviceHeartbeat>, int, int)
public DeviceHeartbeat(ILogger<DeviceHeartbeat> logger, int deviceRequestTimeout = 3000, int deviceActivityGrace = 10000)
Parameters
loggerILogger<DeviceHeartbeat>deviceRequestTimeoutintdeviceActivityGraceint
Fields
DefaultDeviceHeartbeatInterval
public const int DefaultDeviceHeartbeatInterval = 10000
Field Value
Properties
IsRunning
True when the heartbeat has been started and not yet stopped. The background loop may drain briefly after a stop, but exits without invoking events.
public bool IsRunning { get; }
Property Value
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
Resume()
[Obsolete("Use Start() instead. Method will be removed in SDK version 3.")]
public void Resume()
Start(IDeviceMonitor, int)
public Task Start(IDeviceMonitor monitor, int probeInterval_ms)
Parameters
monitorIDeviceMonitorprobeInterval_msint
Returns
Stop()
public Task Stop()
Returns
Suspend()
[Obsolete("Use Stop() instead. Method will be removed in SDK version 3.")]
public void Suspend()
Events
HeartbeatFailed
public event EventHandler<IDevice>? HeartbeatFailed