Expand XML docs across bridge and test code
This commit is contained in:
@@ -19,9 +19,22 @@ namespace ZB.MOM.WW.LmxOpcUa.Host.GalaxyRepository
|
||||
private CancellationTokenSource? _cts;
|
||||
private DateTime? _lastKnownDeployTime;
|
||||
|
||||
/// <summary>
|
||||
/// Occurs when a new Galaxy deploy timestamp indicates the OPC UA address space should be rebuilt.
|
||||
/// </summary>
|
||||
public event Action? OnGalaxyChanged;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the last deploy timestamp observed by the polling loop.
|
||||
/// </summary>
|
||||
public DateTime? LastKnownDeployTime => _lastKnownDeployTime;
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new change detector for Galaxy deploy timestamps.
|
||||
/// </summary>
|
||||
/// <param name="repository">The repository used to query the latest deploy timestamp.</param>
|
||||
/// <param name="intervalSeconds">The polling interval, in seconds, between deploy checks.</param>
|
||||
/// <param name="initialDeployTime">An optional deploy timestamp already known at service startup.</param>
|
||||
public ChangeDetectionService(IGalaxyRepository repository, int intervalSeconds, DateTime? initialDeployTime = null)
|
||||
{
|
||||
_repository = repository;
|
||||
@@ -29,6 +42,9 @@ namespace ZB.MOM.WW.LmxOpcUa.Host.GalaxyRepository
|
||||
_lastKnownDeployTime = initialDeployTime;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Starts the background polling loop that watches for Galaxy deploy changes.
|
||||
/// </summary>
|
||||
public void Start()
|
||||
{
|
||||
_cts = new CancellationTokenSource();
|
||||
@@ -36,6 +52,9 @@ namespace ZB.MOM.WW.LmxOpcUa.Host.GalaxyRepository
|
||||
Log.Information("Change detection started (interval={Interval}s)", _intervalSeconds);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stops the background polling loop.
|
||||
/// </summary>
|
||||
public void Stop()
|
||||
{
|
||||
_cts?.Cancel();
|
||||
@@ -88,6 +107,9 @@ namespace ZB.MOM.WW.LmxOpcUa.Host.GalaxyRepository
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stops the polling loop and disposes the underlying cancellation resources.
|
||||
/// </summary>
|
||||
public void Dispose()
|
||||
{
|
||||
Stop();
|
||||
|
||||
Reference in New Issue
Block a user