flows#

Interfaces#

AtomicSection#

Defined in: flows.ts:29

A stretch of the axis that flow control never divides, named by its letter.

Properties#

end#

readonly end: FlowValue

Defined in: flows.ts:32

name#

readonly name: string

Defined in: flows.ts:30

start#

readonly start: FlowValue

Defined in: flows.ts:31


Flow#

Defined in: flows.ts:67

One flow: the runs in the order played, the names of the atomic sections they cover, in that order, and what playing found (printed, the whole axis, finds nothing).

Properties#

findings#

readonly findings: readonly FlowFinding[]

Defined in: flows.ts:70

runs#

readonly runs: readonly FlowRun[]

Defined in: flows.ts:68

sections#

readonly sections: readonly string[]

Defined in: flows.ts:69


FlowFinding#

Defined in: flows.ts:54

Something playing flow control found: where (the start of the stretch, for a stretch never played, whose end is given too), why, where timetoalign names a cause, and timetoalign’s sentence about it.

Properties#

cause?#

readonly optional cause?: "single_playback"

Defined in: flows.ts:58

coordinate#

readonly coordinate: FlowValue

Defined in: flows.ts:56

end?#

readonly optional end?: FlowValue

Defined in: flows.ts:57

kind#

readonly kind: FlowFindingKind

Defined in: flows.ts:55

message#

readonly message: string

Defined in: flows.ts:59


FlowOptions#

Defined in: flows.ts:86

What flows may be asked besides the timeline.

Properties#

convention?#

readonly optional convention?: FlowConvention

Defined in: flows.ts:88

The one convention to answer; all three without it.

reading?#

readonly optional reading?: FlowReading

Defined in: flows.ts:95

Which flow-control elements are read: those whose state for the reading’s believer is one of its states (core’s flowReading, the editor’s user under the block’s belief filter); without it the elements no actor rejects.


Flows#

Defined in: flows.ts:78

The flows of one timeline: its bare ID, its number type, its atomic sections in the order of the axis, and the flow of each convention asked for.

Properties#

atomic_sections#

readonly atomic_sections: readonly AtomicSection[]

Defined in: flows.ts:81

conventions#

readonly conventions: Readonly<Partial<Record<FlowConvention, Flow>>>

Defined in: flows.ts:82

number_type#

readonly number_type: FlowNumberType

Defined in: flows.ts:80

timeline#

readonly timeline: string

Defined in: flows.ts:79


WrittenFlowOptions#

Defined in: flows.ts:99

What withFlowMaps may be asked besides the timeline.

Extends#

Properties#

actor?#

readonly optional actor?: string

Defined in: flows.ts:105

Who asks: the actor whose belief false rejects an atomic section written before whose stretch is none any more. The server refuses to write over such a section without it.

date?#

readonly optional date?: string

Defined in: flows.ts:107

The day of that belief, YYYY-MM-DD; the server’s day without it.

reading?#

readonly optional reading?: FlowReading

Defined in: flows.ts:95

Which flow-control elements are read: those whose state for the reading’s believer is one of its states (core’s flowReading, the editor’s user under the block’s belief filter); without it the elements no actor rejects.

Inherited from#

FlowOptions.reading

Type Aliases#

FlowConvention#

FlowConvention = "default" | "single" | "printed"

Defined in: flows.ts:13

How flow control is played: as written, once through, or the axis as it stands.


FlowFindingCause#

FlowFindingCause = "single_playback"

Defined in: flows.ts:47

Why a convention found what it found: single_playback, a stretch going through once leaves out that the default flow plays.


FlowFindingKind#

FlowFindingKind = "flow_ends_at_break" | "never_played" | "endless_loop" | "ambiguous_targets" | "undetermined_target"

Defined in: flows.ts:36

What playing flow control can find.


FlowNumberType#

FlowNumberType = "int" | "float" | "fraction"

Defined in: flows.ts:16

The number type of a timeline’s axis, which says how a value on it is written.


FlowRun#

FlowRun = readonly [FlowValue, FlowValue]

Defined in: flows.ts:26

A stretch of the axis played without a jump: its start and its end, exclusive.


FlowValue#

FlowValue = number | readonly [number, number]

Defined in: flows.ts:23

A value on the timeline’s own axis, written as its manifest writes one: an integer under int, a number under float, a [numerator, denominator] pair of safe integers under fraction.

Variables#

MALFORMED_FLOW_MAPS#

const MALFORMED_FLOW_MAPS: "the flow-maps answer is not a manifest" = "the flow-maps answer is not a manifest"

Defined in: flows.ts:114

The message of a flow-maps answer that is no manifest file in JSON.


MALFORMED_FLOWS#

const MALFORMED_FLOWS: "the flows answer is not the flows of the timeline asked for" = "the flows answer is not the flows of the timeline asked for"

Defined in: flows.ts:111

The message of a flows answer that is not of the route’s form.

Functions#

flowsOf()#

flowsOf(body, timeline, convention): Flows | undefined

Defined in: flows.ts:261

The flows of the timeline timeline that a 2xx body of the flows route holds, or undefined when the body is not of its form: the timeline asked, a number type, the atomic sections, and exactly the conventions asked for (convention, or all three), every value written as the number type says and every section of a flow one of the atomic sections.

Parameters#

body#

unknown

timeline#

string

convention#

FlowConvention | undefined

Returns#

Flows | undefined


flowsRequest()#

flowsRequest(timeline, options, manifest): Blob

Defined in: flows.ts:133

A request of the flow routes: the parameters’ UTF-8 length (little-endian), the parameters as JSON (timeline, then convention, the reading’s believer and beliefs, actor and date where given), then the manifest’s text.

Parameters#

timeline#

string

options#

FlowOptions & WrittenFlowOptions

manifest#

string

Returns#

Blob


isManifestText()#

isManifestText(text): boolean

Defined in: flows.ts:291

Whether text is JSON holding an object with a timelines list: a manifest file.

Parameters#

text#

string

Returns#

boolean