MissionMessage class
Backend → Frontend.
Constructors
-
MissionMessage({required String missionId, required List<
MissionStep> steps, String? goal, bool continueOnFailure = false, int? invalidStepIndex, int? declaredStepCount}) -
const
-
MissionMessage.fromJson(Map<
String, dynamic> json) -
Strict parse: throws on a missing
mission_idor any malformed step.factory
Properties
- continueOnFailure → bool
-
Tour semantics (Android
MissionMessage.continueOnFailure): a failed step is reported as a non-terminalstep_failedand SKIPPED instead of aborting the mission. Parsed strictly — only a JSONtrueturns it on.final - declaredStepCount → int
-
How many steps the frame declared (parsed or not) —
steps_totalon the terminal frame of a malformed mission.no setter - goal → String?
-
Optional human-readable goal.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- invalidStepIndex → int?
-
Index of the first step that could not be parsed, or null for a
well-formed mission. A malformed mission is still dispatched so the
runner can answer
failed failure_reason=invalid_missioninstead of silently dropping the frame.final - isValid → bool
-
no setter
- missionId → String
-
Backend-assigned ID.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
steps
→ List<
MissionStep> -
final
- type → String
-
no setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
tryParse(
Map< String, dynamic> json) → MissionMessage? -
Defensive parse. Null ONLY when
mission_idis missing / not a non-empty string (nothing can be reported back for such a frame). A malformed step yields a mission with invalidStepIndex set.