SingleChildStatelessBranch class
Mounted branch for a SingleChildStatelessSeed: a StatelessBranch that, inside a Nest, builds with the injected downstream instead of the seed's own child.
- Inheritance
-
- Object
- Branch
- ComponentBranch
- StatelessBranch
- SingleChildStatelessBranch
- Mixed-in types
Constructors
- SingleChildStatelessBranch(SingleChildStatelessSeed seed)
-
Creates the branch for
seed.
Properties
- branchId ↔ String
-
Stable id for this mounted branch; assigned at mount time via
TreeOwner.issueId and never changes during the branch's lifetime.
latefinalinherited
- child → Branch?
-
The mounted child branch built by build. Exposed for testing.
Do not use in production code.
no setterinherited
- context → TreeContext
-
The capability handle for this branch.
no setterinherited
-
dependencies
→ Set<
Branch> -
Providers this branch depends on. Exposed for testing.
Do not use in production code.
no setterinherited
- depth ↔ int
-
Depth from the root (root = 0). Drives the owner's depth-ordered flush.
getter/setter pairinherited
- dirty → bool
-
Whether this branch is currently marked as needing rebuild.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- injectedChild → Seed?
-
The downstream supplied by the enclosing Nest link, or null when this
branch is used standalone (outside a chain).
no setterinherited
- key → Key?
-
The Key of the underlying Seed config, or null if unkeyed.
no setterinherited
- mounted → bool
-
Whether this branch is currently mounted in a tree.
no setterinherited
- owner ↔ TreeOwner?
-
The TreeOwner this branch is mounted under. Set by
TreeOwner.mountRoot for roots and inherited from the parent in
mount.
getter/setter pairinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- seed → Seed
-
The current Seed configuration for this branch.
no setterinherited
Methods
-
build(
TreeContext context) → Seed -
Builds the child configuration.
contextis this branch's capability handle — never the branch itself.override -
debugDescribeChildren(
) → List< Diagnosticable> -
Returns this object's diagnostic children in display order.
inherited
-
debugFillProperties(
DiagnosticsBuilder properties) → void -
Adds this object's diagnostic properties to
properties.inherited -
dependencyChanged(
) → void -
Called by
InheritedBranchwhen a depended-on value changes. Default: delegates to markNeedsRebuild.StatefulBranchoverrides this to also flag didChangeDependencies.inherited -
dependOnInheritedSeedOfExactType<
T extends Object> ({Object? aspect}) → T? -
Returns the nearest ancestor value provided via
InheritedSeed<T>of exact typeT, registering this branch as a dependent; null when no such ancestor exists.inherited -
getInheritedSeedOfExactType<
T extends Object> () → T? -
Returns the nearest ancestor value provided via
InheritedSeed<T>of exact typeTwithout registering a dependency; null when no such ancestor exists.inherited -
markNeedsRebuild(
) → void -
Marks this branch dirty so the next TreeOwner.flush rebuilds it.
inherited
-
mount(
Branch? parent, Object? slot) → void -
Attaches this branch into the tree under
parentatslot.inherited -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
performRebuild(
) → void -
The single rebuild hook.
Branchcore attaches no meaning to it; the composition layer defines it as re-runningbuild(), and non-component branches define their own rebuild behavior.inherited -
rebuild(
{bool force = false}) → void -
Runs performRebuild when this branch is mounted and dirty (or when
forceis true — the update path). Clears the dirty flag first, so a branch force-rebuilt during reconciliation is skipped when the owner later drains it in the same flush.inherited -
removeDependency(
Branch dep) → void -
Package-internal: called only by
InheritedBranch.removeDependent.inherited -
toString(
) → String -
A string representation of this object.
inherited
-
toStringDeep(
) → String -
Returns a deterministic multiline description of this object.
inherited
-
unmount(
) → void -
Detaches this branch from the tree.
inherited
-
update(
Seed newSeed) → void -
Updates the config node when Seed.canUpdate is true, then invokes the
rebuild path: a config update reaches performRebuild with the new
seed already in place. What the hook does is layered — components
re-run
build(); non-component branches respond with their own rebuild semantics.inherited -
updateChild(
Branch? child, Seed? newSeed, Object? slot) → Branch? -
Reconciles
childagainstnewSeedatslot.inherited -
updateChildren(
List< Branch> oldChildren, List<Seed> newSeeds) → List<Branch> -
Reconciles
oldChildrenagainstnewSeedsby key identity.inherited -
visitChildren(
void visitor(Branch dep)) → void -
Calls
visitoronce for each direct child of this branch, in tree order.inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited