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?#
readonlyoptionalid?:string
Defined in: manifest/statements.ts:115
provenance?#
readonlyoptionalprovenance?: readonlyobject[]
Defined in: manifest/statements.ts:117
statements?#
readonlyoptionalstatements?: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#
readonlytimelines: readonlySkeletonTimeline[]
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#
readonlyid:string
Defined in: manifest/statements.ts:98
provenance?#
readonlyoptionalprovenance?: readonlyobject[]
Defined in: manifest/statements.ts:100
statements?#
readonlyoptionalstatements?: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#
readonlychildren: readonlySkeletonTimeline[]
Defined in: manifest/statements.ts:106
id#
readonlyid:string
Defined in: manifest/statements.ts:98
Inherited from#
provenance?#
readonlyoptionalprovenance?: readonlyobject[]
Defined in: manifest/statements.ts:100
Inherited from#
regions#
readonlyregions: readonlySkeletonRegion[]
Defined in: manifest/statements.ts:105
statements?#
readonlyoptionalstatements?: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#
StatementHolder#
Defined in: manifest/statements.ts:34
One element that may carry statements, with what it carries.
Properties#
id#
readonlyid:string|null
Defined in: manifest/statements.ts:37
The element’s bare ID; null for the manifest.
kind#
readonlykind:HolderKind
Defined in: manifest/statements.ts:35
name#
readonlyname:string|null
Defined in: manifest/statements.ts:39
The element’s name; null where it states none.
path#
readonlypath: readonlyPathSegment[]
Defined in: manifest/statements.ts:41
The element’s path from the manifest: [] for the manifest, ["timelines", 1, "children", 0], …
provenance#
readonlyprovenance: readonlyobject[] |undefined
Defined in: manifest/statements.ts:43
statements#
readonlystatements: {[key:string]: readonlystring[] | readonly (string|boolean|JsonNumber| { } | {[key:string]:string| readonlyobject[] | readonlystring[] | 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#
Returns#
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#
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#
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#
removed#
ReadonlySet<string>
Returns#
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