Anchor class final

A typed handle that names an element's timeline so triggers can reference it — no strings, so autocomplete, rename-refactor, and "find usages" work.

Attach an anchor where you declare an element, then chain off it:

final intro = Anchor('intro');

Text('Title').animate([Animation.pop()], anchor: intro);
Text('Subtitle').animate([Animation.fadeIn(at: Trigger.after(intro))]);

An anchor is a token: equality is reference identity, never value equality. Two Anchor('x') are distinct handles naming distinct timelines — this is load-bearing for the trigger resolver, which keys its dependency graph by anchor instance. For the same reason the constructor is deliberately non-const: const canonicalization would silently merge equal-looking anchors.

Constructors

Anchor([String? debugName])
Creates a fresh, unique anchor, optionally tagged with debugName.

Properties

debugName String?
A label used only in diagnostics (timeline dumps, error messages).
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

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