using System;
using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;
namespace ZB.MOM.WW.LmxOpcUa.Host.Domain
{
///
/// Interface for Galaxy repository database queries. (GR-001 through GR-004)
///
public interface IGalaxyRepository
{
///
/// Retrieves the Galaxy object hierarchy used to construct the OPC UA browse tree.
///
/// A token that cancels the repository query.
/// A list of Galaxy objects ordered for address-space construction.
Task> GetHierarchyAsync(CancellationToken ct = default);
///
/// Retrieves the Galaxy attributes that become OPC UA variables under the object hierarchy.
///
/// A token that cancels the repository query.
/// A list of attribute definitions with MXAccess references and type metadata.
Task> GetAttributesAsync(CancellationToken ct = default);
///
/// Gets the last Galaxy deploy timestamp used to detect metadata changes that require an address-space rebuild.
///
/// A token that cancels the repository query.
/// The latest deploy timestamp, or when it cannot be determined.
Task GetLastDeployTimeAsync(CancellationToken ct = default);
///
/// Verifies that the service can reach the Galaxy repository before it attempts to build the address space.
///
/// A token that cancels the connectivity check.
/// when repository access succeeds; otherwise, .
Task TestConnectionAsync(CancellationToken ct = default);
///
/// Occurs when the repository detects a Galaxy deployment change that should trigger an OPC UA rebuild.
///
event Action? OnGalaxyChanged;
}
}