ActivitySnapshotEvent class abstract
ACTIVITY_SNAPSHOT — a frontend-only structured-UI element (progress bar,
checklist, …) keyed by messageId and activityType. Activity content
never reaches the agent; it is rendered by the consumer surface (Epic 6/7).
content is the full activity payload (Record<string, any> on the wire);
the nested object is compared deeply via freezed's DeepCollectionEquality.
replace mirrors the wire flag (defaulting to true on the wire) but is
not defaulted here: an absent flag stays null so the round-trip is
lossless, and the snapshot-vs-merge decision is left to the consumer.
- Inheritance
- Available extensions
- Annotations
-
- @freezed
Constructors
Properties
- activityType → String
-
no setterinherited
-
content
→ Map<
String, dynamic> -
no setterinherited
-
copyWith
→ $ActivitySnapshotEventCopyWith<
ActivitySnapshotEvent> -
Create a copy of ActivitySnapshotEvent
with the given fields replaced by the non-null parameter values.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- messageId → String
-
no setterinherited
- replace → bool?
-
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
map<
TResult extends Object?> (TResult $default(_ActivitySnapshotEvent value)) → TResult -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_ActivitySnapshotEvent value)?) → TResult? -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_ActivitySnapshotEvent value)?, {required TResult orElse()}) → TResult -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> (TResult $default(String messageId, String activityType, Map< String, dynamic> content, bool? replace)?, {required TResult orElse()}) → TResult -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes to the
ACTIVITY_SNAPSHOTwire shape. -
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> (TResult $default(String messageId, String activityType, Map< String, dynamic> content, bool? replace)) → TResult -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> (TResult? $default(String messageId, String activityType, Map< String, dynamic> content, bool? replace)?) → TResult? -
Available on ActivitySnapshotEvent, provided by the ActivitySnapshotEventPatterns extension
A variant ofwhenthat fallback to returningnull
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJson(
Map< String, dynamic> json) → ActivitySnapshotEvent -
Decodes an
ACTIVITY_SNAPSHOTwire payload. Throws ProtocolError(protocolMalformed)whenmessageId/activityTypeis absent orcontentis absent/not a JSON object; a present non-boolreplaceis likewise rejected (absentreplacedecodes tonull).