IF Commons GitHub

re-exports

What Ontology exports from elsewhere, so that its users need import nothing else.

3 of 17 exports are imported by a test of the run. A test that imports an export may not call it or check what it returns.

codeOffunctionno test imports it
function codeOf<K extends string>(list: { readonly [N in K]: Named; }, node: Named): K | undefined

Declared in commons/rdf/src/rdf-schema.ts

The key of a code list that names an individual, or nothing where none does.

formatRdfFindingfunctionno test imports it
function formatRdfFinding(f: RdfFinding): string

Declared in commons/rdf/src/rdf-schema.ts

The sentence a finding is told with.

nTriplesfunctionno test imports it
function nTriples(triples: readonly Triple[]): string

Declared in commons/rdf/src/rdf-write.ts

Triples as N-Triples: each once, one a line, the lines in the order of their code points.

triplesOffunction
function triplesOf(individuals: readonly AnyIndividual[]): readonly Triple[]

Declared in commons/rdf/src/rdf-schema.ts

The triples of individuals: each individual's statements in order, each triple once, where first stated.

Imported by 7 tests of the run (6 passed, 0 failed): the library's results

turtlefunction
function turtle(doc: TurtleDocument): string

Declared in commons/rdf/src/rdf-write.ts

Triples as Turtle in its canonical form: the comment lines, then the prefixes sorted by name, then the subjects in the order of their N-Triples terms, each with its rdf:type first as a and its other predicates by IRI, each predicate's objects in the order of their N-Triples terms, one blank line between subjects. An IRI is a prefixed name where a prefix's IRI starts it and the rest is a plain local name (the longest such prefix), and a whole IRI otherwise; an integer or a boolean of canonical form is written bare.

Imported by 7 tests of the run (6 passed, 0 failed): the library's results

validatefunction
function validate(individuals: readonly AnyIndividual[]): readonly RdfFinding[]

Declared in commons/rdf/src/rdf-schema.ts

Every finding about the individuals, in the order they are stated.

Imported by 48 tests of the run (47 passed, 0 failed): the library's results

Iritypeno test imports it
type Iri = Brand<string, "rdf/Iri">;

Declared in commons/rdf/src/rdf-term.ts

An absolute IRI, checked by parseIri or made from a namespace.

Namedtypeno test imports it
type Named<C extends string = never> = { readonly kind: "named"; readonly iri: Iri; readonly "@ifc/rdf-classes": Classes<C> };

Declared in commons/rdf/src/rdf-term.ts

A named node: an IRI, branded with the classes its term is an individual of (by their CURIEs, "pm:PackageManager"). A Named<"a" | "b"> is an individual of both, so it is accepted where either is asked for; a Named<"a"> is not accepted where "b" is, and a Named of no known class (Named, which is Named<never>) is not accepted where any one class is asked for: every named node is a Named, so it is the type of a predicate or of any node at all.

Namespacetypeno test imports it
type Namespace<P extends string = string> = { readonly prefix: P; readonly iri: Iri };

Declared in commons/rdf/src/rdf-term.ts

A namespace: a prefix and the IRI its terms' local names are appended to.

OntologyFiletypeno test imports it
type OntologyFile = {
  readonly name: string;
  readonly prefixes: readonly Namespace[];
  readonly individuals: readonly AnyIndividual[];
};

Declared in commons/rdf/src/rdf-schema.ts

One file of an ontology: its name, the prefixes its Turtle may write, and the individuals it states, in order.

RdfFindingtypeno test imports it
type RdfFinding =
  | { readonly kind: "not-an-integer"; readonly subject: Iri; readonly predicate: Iri; readonly value: number }
  | {
      readonly kind: "not-one-of";
      readonly subject: Iri;
      readonly predicate: Iri;
      readonly value: string;
      readonly words: readonly string[];
    }
  | { readonly kind: "stated-twice"; readonly subject: Iri };

Declared in commons/rdf/src/rdf-schema.ts

What a type cannot state about individuals (or what a run without the type checker lets through): an integer that is not a safe integer, a word not of its field's list, or a subject stated twice.

DCTERMSconstno test imports it
const DCTERMS: Namespace<"dcterms">

Declared in commons/rdf/src/rdf-vocabularies.ts

The namespace of the Dublin Core terms.

OWLconstno test imports it
const OWL: Namespace<"owl">

Declared in commons/rdf/src/rdf-vocabularies.ts

The namespace of OWL 2.

owlconstno test imports it
const owl: Vocabulary<"owl", { readonly Ontology: "rdfs:Class"; readonly Class: "rdfs:Class"; readonly ObjectProperty: "… (473 characters)
const owl: Vocabulary<"owl", { readonly Ontology: "rdfs:Class"; readonly Class: "rdfs:Class"; readonly ObjectProperty: "rdfs:Class"; readonly DatatypeProperty: "rdfs:Class"; readonly AnnotationProperty: "rdfs:Class"; readonly NamedIndividual: "rdfs:Class"; readonly Thing: "rdfs:Class"; readonly versionInfo: "rdf:Property"; readonly versionIRI: "rdf:Property"; readonly imports: "rdf:Property"; readonly sameAs: "rdf:Property"; readonly equivalentClass: "rdf:Property"; }>

Declared in commons/rdf/src/rdf-vocabularies.ts

The terms of owl: that commons states.

RDFSconstno test imports it
const RDFS: Namespace<"rdfs">

Declared in commons/rdf/src/rdf-vocabularies.ts

The namespace of RDF Schema.

SKOSconstno test imports it
const SKOS: Namespace<"skos">

Declared in commons/rdf/src/rdf-vocabularies.ts

The namespace of SKOS.

XSDconstno test imports it
const XSD: Namespace<"xsd">

Declared in commons/rdf/src/rdf-vocabularies.ts

The namespace of the XML Schema datatypes.

Titles, headings, exports, tables, columns and requirements. Esc closes.