patchbayUiSemanticsTreeCommandDescriptor top-level property
Implementation
final patchbayUiSemanticsTreeCommandDescriptor = _ui(
'ui.semantics.tree',
'Observe the current Flutter Semantics tree.',
mode: PatchbayCommandMode.readOnly,
effect: PatchbaySideEffect.none,
parameters: <PatchbayParameterDescriptor>[
_p('maxDepth', PatchbayParameterType.integer, defaultValue: 64),
_p('maxNodes', PatchbayParameterType.integer, defaultValue: 1000),
_p('inputWasStdin', PatchbayParameterType.boolean),
],
cliSyntax: const <PatchbayCliSyntax>[
PatchbayCliSyntax(
id: 'uiSemanticsTree',
path: <String>['ui', 'semantics', 'tree'],
summary: 'Read the Patchbay semantics tree.',
inputMode: PatchbayCliInputMode.mergedJsonObject,
),
],
// PB-050-40: the one unbounded member and the one brief deletion this
// command has always had, moved off the CLI's hand-written tables and onto
// the descriptor the host actually publishes. `nodes` is both the member
// that spills to a local artifact and the member brief deletes, and the
// interpreter runs the artifact first, so a spilled response keeps its
// receipt instead of losing it to the deny-list.
outputProjection: const PatchbayOutputProjection(
brief: PatchbayOutputBriefProjection(
id: 'ui.semantics.tree',
omit: <String>[r'$.payload.nodes'],
),
artifact: PatchbayOutputArtifactProjection.renderedMember(
member: r'$.payload.nodes',
encoding: PatchbayOutputArtifactEncoding.json,
),
),
);