LibTmux.Selection
Source and package
- Qualified name
-
LibTmux:: Selection - Declared in
LibTmux- Package
- LibTmux
- Source
- lib/LibTmux/Selection.rakumod
-
Description#
Captured selections
A concrete selection consumes
Selection[Pane, 'pane']or another catalogue entity schema.new(:items)copies finite, eager, defined membership. It does not deep-clone member objects. Observation classes must supply their own read-only field contract.Binding
my @panes := $snapshot.panespreserves the selection. Array assignment materializes ordinary array membership; assigning to a scalar itemizes the selection. Use$panes.Listwhen explicit list traversal is wanted. Each iterator and Seq is fresh. Array conversion is independently mutable; List membership cannot be replaced.whereaccepts criterion data or a compiled Filter and validates the schema before traversal.filterinvokes one callback per member, eagerly in source order, and throws a directly returned Failure before Boolean coercion. Both return the same concrete selection type and preserve order and duplicates. Nativegrep,map,sort,firstand junctions delegate to the captured List, including grep adverbs. They retain native return and evaluation rules.oneconstructs a junction; exact cardinality usessingle.