namespace ZB.MOM.WW.OtOpcUa.Core.Abstractions;
///
/// Optional composable driver capability: the driver consumes other tags' live values.
/// The host registers the declared with its per-node dependency mux
/// and forwards every matching value change into — the seam that
/// lets a host-blind driver (e.g. the Calculation pseudo-driver) read the address space's
/// live values without any cross-driver plumbing of its own.
///
///
///
/// The mechanism mirrors how a VirtualTagActor registers interest on the
/// DependencyMuxActor: the mux already receives every driver's
/// AttributeValuePublished keyed by wire-ref (under v3, RawPath), so a driver that
/// implements this interface simply piggy-backs on that fan-out. A calc tag's computed output
/// re-enters the mux via the ordinary driver publish path, so calc-of-calc chains work with no
/// extra machinery — which is exactly why the deploy-time cycle gate is mandatory.
///
///
/// Implementations of are invoked from an actor context and
/// must be non-blocking — do the work inline and cheaply (the compile cache makes
/// steady-state calc evaluation a bounded method invocation), never block on I/O.
///
///
public interface IDependencyConsumer
{
///
/// Wire-refs (RawPaths) this driver needs fed to it, derived from its authored tags. The host
/// re-reads this after /
/// and (re)registers the set with its dependency mux on every apply, so a tag/script edit that
/// changes the set converges without a bespoke notification.
///
IReadOnlyCollection DependencyRefs { get; }
///
/// Host push of a single dependency value change. Called from an actor context, so the
/// implementation must be non-blocking.
///
/// The changed dependency's wire-ref (RawPath).
/// The new value (may be null).
/// The OPC UA status code carried with the value (0 = Good).
/// The source timestamp of the change.
void OnDependencyValue(string rawPath, object? value, uint statusCode, DateTime timestampUtc);
}