Files
HomeAssistant/NordPool.Models/NordPoolConsts.cs
T
Marius 28eddc5dc0 Add cancellation token support across NordPool services and update constants for reuse
- Introduced `CancellationToken` to service methods for improved task cancellation handling.
- Centralized reusable constants (`MinutesPerInterval`, `WaterReadyPowerThresholdWatts`) in `NordPoolConsts`.
- Refactored `ConfigureAwait` usage and improved logging within `NordPoolEntityService`.
- Adjusted tests to accommodate cancellation token changes.
2026-03-16 12:13:19 +02:00

16 lines
507 B
C#

namespace NordPool.Models;
public static class NordPoolConsts
{
public static readonly string ConfigEntry = "01K9HYQE4Y0E7KC36JZV11MEXH";
/// <summary>
/// NordPool electricity market uses 15-minute trading intervals.
/// </summary>
public const int MinutesPerInterval = 15;
/// <summary>
/// Power threshold in watts below which the boiler is considered to have finished heating (water ready).
/// </summary>
public const double WaterReadyPowerThresholdWatts = 5.0;
}