path_start library

Reading the entry that starts a trajectory, for its rules, without decoding what strangers sent: for the airlock.

Classes

AdmittedTrajectoryEntry<R>
What an event-admitted-to-mission entry says about the trajectories it starts: EntryStartsTrajectory, EntryStartsNoTrajectory, or UnreadableTrajectoryEntry. A reader that enforces rules must stop on the last: a trajectory it skipped is one whose rules it never learnt.
EntryStartsNoTrajectory<R>
The entry is read, and starts no trajectory: it goes under one already started, or is a join.
EntryStartsTrajectory<R>
The entry starts trajectory, in mission, under rules, with its replies going to replyEndpoint.
UnreadableTrajectoryEntry<R>
The entry is not one encodeDecision writes as event-admitted-to-mission, for the reason why.

Functions

readTrajectoryStart<R>(Uint8List entry, {required R? rules(Object? json)}) → AdmittedTrajectoryEntry<R>
The logbook entry entry (its bytes as the logbook holds them, the <kind>\n<previous>\n header included, which its ids are hashes of), read for the trajectory it starts. rules reads the rules from their JSON, null when they aren't rules.