manifest/statements#

Interfaces#

Skeleton#

Defined in: manifest/statements.ts:113

The statements of a manifest alone, every element at the index it has in the manifest, so that a path of the skeleton is a path of the manifest.

Properties#

@context#

readonly @context: JsonObject

Defined in: manifest/statements.ts:114

id?#

readonly optional id?: string

Defined in: manifest/statements.ts:115

provenance?#

readonly optional provenance?: readonly object[]

Defined in: manifest/statements.ts:117

statements?#

readonly optional statements?: object

Defined in: manifest/statements.ts:116

Index Signature#

[key: string]: readonly string[] | readonly (string | boolean | JsonNumber | { } | {[key: string]: string | readonly object[] | readonly string[] | readonly (string | boolean | JsonNumber | { readonly “@value”: string; readonly “@language”?: string; readonly “@type”?: string; } | { readonly [x: string]: string | readonly { readonly stated_by?: readonly string[]; readonly date?: string; … 7 more …; readonly value: string | … 4 more … | { …; }; }[] | re… | undefined; } | { })[] | undefined

timelines#

readonly timelines: readonly SkeletonTimeline[]

Defined in: manifest/statements.ts:118


SkeletonRegion#

Defined in: manifest/statements.ts:97

A region of a skeleton: its ID and what it states.

Extended by#

Properties#

id#

readonly id: string

Defined in: manifest/statements.ts:98

provenance?#

readonly optional provenance?: readonly object[]

Defined in: manifest/statements.ts:100

statements?#

readonly optional statements?: object

Defined in: manifest/statements.ts:99

Index Signature#

[key: string]: readonly string[] | readonly (string | boolean | JsonNumber | { } | {[key: string]: string | readonly object[] | readonly string[] | readonly (string | boolean | JsonNumber | { readonly “@value”: string; readonly “@language”?: string; readonly “@type”?: string; } | { readonly [x: string]: string | readonly { readonly stated_by?: readonly string[]; readonly date?: string; … 7 more …; readonly value: string | … 4 more … | { …; }; }[] | re… | undefined; } | { })[] | undefined


SkeletonTimeline#

Defined in: manifest/statements.ts:104

A timeline of a skeleton: its ID, what it states, its regions and its children.

Extends#

Properties#

children#

readonly children: readonly SkeletonTimeline[]

Defined in: manifest/statements.ts:106

id#

readonly id: string

Defined in: manifest/statements.ts:98

Inherited from#

SkeletonRegion.id

provenance?#

readonly optional provenance?: readonly object[]

Defined in: manifest/statements.ts:100

Inherited from#

SkeletonRegion.provenance

regions#

readonly regions: readonly SkeletonRegion[]

Defined in: manifest/statements.ts:105

statements?#

readonly optional statements?: object

Defined in: manifest/statements.ts:99

Index Signature#

[key: string]: readonly string[] | readonly (string | boolean | JsonNumber | { } | {[key: string]: string | readonly object[] | readonly string[] | readonly (string | boolean | JsonNumber | { readonly “@value”: string; readonly “@language”?: string; readonly “@type”?: string; } | { readonly [x: string]: string | readonly { readonly stated_by?: readonly string[]; readonly date?: string; … 7 more …; readonly value: string | … 4 more … | { …; }; }[] | re… | undefined; } | { })[] | undefined

Inherited from#

SkeletonRegion.statements


StatementHolder#

Defined in: manifest/statements.ts:34

One element that may carry statements, with what it carries.

Properties#

id#

readonly id: string | null

Defined in: manifest/statements.ts:37

The element’s bare ID; null for the manifest.

kind#

readonly kind: HolderKind

Defined in: manifest/statements.ts:35

name#

readonly name: string | null

Defined in: manifest/statements.ts:39

The element’s name; null where it states none.

path#

readonly path: readonly PathSegment[]

Defined in: manifest/statements.ts:41

The element’s path from the manifest: [] for the manifest, ["timelines", 1, "children", 0], …

provenance#

readonly provenance: readonly object[] | undefined

Defined in: manifest/statements.ts:43

statements#

readonly statements: {[key: string]: readonly string[] | readonly (string | boolean | JsonNumber | { } | {[key: string]: string | readonly object[] | readonly string[] | readonly (string | boolean | JsonNumber | { readonly “@value”: string; readonly “@language”?: string; readonly “@type”?: string; } | { readonly [x: string]: string | readonly { readonly stated_by?: readonly string[]; readonly date?: string; … 7 more …; readonly value: string | … 4 more … | { …; }; }[] | re… | undefined; } | { })[] | undefined; } | undefined

Defined in: manifest/statements.ts:42

Type Aliases#

HolderKind#

HolderKind = "manifest" | "timeline" | "region"

Defined in: manifest/statements.ts:31

The kinds of element that carry statements.

Functions#

skeletonOf()#

skeletonOf(manifest): Skeleton

Defined in: manifest/statements.ts:153

The statements of manifest alone, at the paths they have in it, with the full context a file writes (fullContext: the format’s terms and every prefix the statements use). The schema package’s statement functions run on it, never on a manifest core holds: they return deep copies, and a copy made structurally would lose what core reads losslessly. Memoised by identity.

Parameters#

manifest#

Manifest

Returns#

Skeleton


statementHolder()#

statementHolder(manifest, id): StatementHolder | undefined

Defined in: manifest/statements.ts:88

The element of manifest with the bare ID id that may carry statements (null: the manifest itself); undefined where no timeline or region has it.

Parameters#

manifest#

Manifest

id#

string | null

Returns#

StatementHolder | undefined


statementHolders()#

statementHolders(manifest): Generator<StatementHolder>

Defined in: manifest/statements.ts:51

Every element of manifest that may carry statements, in subject order: the manifest, then root by root the timeline, its regions in their order, its children depth first.

Parameters#

manifest#

Manifest

Returns#

Generator<StatementHolder>


withContextOf()#

withContextOf<T>(manifest, form): T

Defined in: manifest/statements.ts:261

manifest with the @context of form, another form of the same manifest: in the place the member has, else last; no @context where form has none; manifest itself where its @context is that one already, and where either is no object.

Type Parameters#

T#

T extends object

Parameters#

manifest#

T

form#

object

Returns#

T


withFullContext()#

withFullContext<T>(manifest): T

Defined in: manifest/statements.ts:216

manifest with the full context a file writes (fullContext) as its @context, in the place the member has, else last: the form in which a manifest leaves core for a file or the schema check. manifest itself where that context is its own already, and where its @context is no object, which the schema check then refuses.

Type Parameters#

T#

T extends object

Parameters#

manifest#

T

Returns#

T


withoutReferencesTo()#

withoutReferencesTo(manifest, removed): Manifest

Defined in: manifest/statements.ts:425

manifest without the references to the elements whose bare IDs removed holds, in the statements and provenance of every element: a value that is a node naming one ({id: "#X"}) is dropped, as is a provenance entry whose value names one; #X is dropped from every basis and stated_by, a service #X is dropped; a list, an ordered list, a node, a container or a provenance left empty loses its key. A reference into another manifest (other.yaml#X) is kept. manifest itself where nothing names a removed element.

Parameters#

manifest#

Manifest

removed#

ReadonlySet<string>

Returns#

Manifest


withStatementContext()#

withStatementContext<T>(manifest): T

Defined in: manifest/statements.ts:239

manifest with the @context core holds: of its own @context, only the prefixes it declares itself (no format term, no catalogue prefix with the same namespace) that its statements and provenance use, in their order; no @context where none is left. manifest itself where that is its @context already, and where its @context is no object, which the schema check then refuses.

Type Parameters#

T#

T extends object

Parameters#

manifest#

T

Returns#

T