Files
ScadaBridge/src/ZB.MOM.WW.ScadaBridge.Commons/Messages/Management/BrowseCommands.cs
T
Joseph Doherty 9b7916bb2e refactor(browse): rename BrowseOpcUaNode* to protocol-agnostic BrowseNode*
Renames BrowseOpcUaNodeCommand/Result -> BrowseNodeCommand/Result and
CommunicationService.BrowseOpcUaNodeAsync -> BrowseNodeAsync across Commons,
Communication, SiteRuntime, DCL actors, and CentralUI. Wire manifest name
follows (BrowseOpcUaNode -> BrowseNode). Browse regression tests green.
2026-05-29 07:57:36 -04:00

39 lines
1.3 KiB
C#

using ZB.MOM.WW.ScadaBridge.Commons.Interfaces.Protocol;
namespace ZB.MOM.WW.ScadaBridge.Commons.Messages.Management;
/// <summary>
/// Sent from CentralUI to a specific site to enumerate the immediate children
/// of an OPC UA node on the live server backing the given data connection.
/// </summary>
/// <remarks>
/// Keyed by <see cref="ConnectionName"/> (not id) because the site-side
/// <c>DataConnectionManagerActor</c> indexes its children by connection name —
/// the central UI already has the connection name in scope (dropdown), so a
/// string carries no extra plumbing across the trust boundary. The central
/// <c>DataConnections</c> table's id is intentionally not exposed at the site.
/// </remarks>
/// <param name="ConnectionName">Name of the site-local data connection to browse against.</param>
/// <param name="ParentNodeId">Node to browse, or null to browse from the server root (ObjectsFolder).</param>
public record BrowseNodeCommand(
string ConnectionName,
string? ParentNodeId);
public record BrowseNodeResult(
IReadOnlyList<BrowseNode> Children,
bool Truncated,
BrowseFailure? Failure);
public record BrowseFailure(
BrowseFailureKind Kind,
string Message);
public enum BrowseFailureKind
{
ConnectionNotFound,
ConnectionNotConnected,
NotBrowsable,
Timeout,
ServerError
}