UiNode class

A node in an agent-authored component tree.

The shape is intentionally minimal and pure-Dart: every field is observable over the wire to the host UI. No package:flutter types appear here.

Constructors

UiNode({required String type, Map<String, Object?> props = const <String, Object?>{}, List<UiNode> children = const <UiNode>[], String? styleToken, String? actionId, ActionTier? actionTier})
const

Properties

actionId → String?
Optional semantic action id. When non-null, the host UI treats this node as interactive; a tap emits a SemanticAction with this id (spec FR-004).
final
actionTier → ActionTier?
Optional action tier override. When null and actionId is non-null, the action defaults to ActionTier.safe. Set to ActionTier.confirm for risky actions that must pass through the PolicyGate (spec FR-006).
final
children → List<UiNode>
Child nodes.
final
hashCode → int
The hash code for this object.
no setterinherited
hasInteractive → bool
Whether this subtree contains any node with a non-null actionId.
no setter
nodeCount → int
Count of all nodes in this subtree (self + descendants).
no setter
props → Map<String, Object?>
Component properties (string→primitive/node refs). Free-form so the schema can evolve without breaking the runtime; schema validation only checks node types and style tokens, not prop keys.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
styleToken → String?
Optional style token — must be present in UiVocabularySchema.allowedStyleTokens when non-null.
final
type → String
Component type, e.g. card, button, text, container.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited