Response class

What the consumer did. The outcome is the load-bearing member: it is what tells the producer whether a compensating action is required, since SPEC.md §11.4 declines to require rollback.

Constructors

Response({required Object? operation, required ResponseTarget target, required Object? outcome, List<ResponseEffectsItem>? effects, Map<String, dynamic>? ext})
const
Response.fromJson(Map<String, dynamic> json)
Read this payload from a decoded JSON object.
factory

Properties

effects → List<ResponseEffectsItem>?
What was created, changed, disclosed, or exercised before the operation took hold. A consumer MUST populate this where outcome is appliedWithEffects or alreadyCompleted — a producer cannot decide whether to compensate without it — and the specification's Conformance section carries that requirement normatively. It is not expressed as a conditional schema because the registry's Rust code generator does not support if/then/else. The framework does not constrain how a task describes its own effects.
final
ext → Map<String, dynamic>?
Vendor-namespaced extension data per SPEC.md §4.5.1.
final
hashCode → int
The hash code for this object.
no setterinherited
operation → Object?
Echoed from the request, so the response is self-describing when retained apart from it.
final
outcome → Object?
applied — the operation took effect and NO irreversible or externally visible effect had occurred. The only outcome that means the task left no trace. appliedWithEffects — the operation took effect, but effects had already occurred before it did. effects describes them. A consumer MUST NOT report applied in this case (SPEC.md §11.3). alreadyCompleted — the task finished before the control document was processed. Not a cancellation; whether to compensate is the producer's own decision. unknownTask — the consumer holds no record of the target id, either because it never received it or because its acceptance window has lapsed. A consumer that records the operation as a tombstone against a not-yet-arrived document reports applied, not this.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
target → ResponseTarget
Echoed from the request.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
Serialize to a JSON-encodable map, omitting absent members.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited