hydra.rdf.shacl_rdf module
Serialize a SHACL ShapesGraph to RDF triples using the SHACL vocabulary.
- hydra.rdf.shacl_rdf.common_constraint_to_triples(subj: Resource, cc: CommonConstraint) Sequence[Triple]
Serialize a CommonConstraint to triples.
- hydra.rdf.shacl_rdf.common_properties_to_triples(subj: Resource, cp: CommonProperties) Sequence[Triple]
Serialize CommonProperties to triples.
- hydra.rdf.shacl_rdf.definition_to_triples(d: Definition[Shape]) Sequence[Triple]
Serialize a Definition<Shape> to triples.
- hydra.rdf.shacl_rdf.iri_or_literal_to_node(il: IriOrLiteral) Node_
Convert an IriOrLiteral to an RDF Node.
- hydra.rdf.shacl_rdf.node_shape_to_triples(iri_: Iri, ns_: NodeShape) Sequence[Triple]
Serialize a NodeShape to triples.
- hydra.rdf.shacl_rdf.property_ref_to_triples(subj: Resource, ref: object) Sequence[Triple]
Serialize a property shape reference (may be inline or named).
- hydra.rdf.shacl_rdf.property_shape_constraint_to_triples(subj: Resource, psc: PropertyShapeConstraint) Sequence[Triple]
Serialize a PropertyShapeConstraint to triples.
- hydra.rdf.shacl_rdf.property_shape_to_triples(subj: Resource, ps: PropertyShape) Sequence[Triple]
Serialize a PropertyShape to triples, given a subject resource (may be blank node).
- hydra.rdf.shacl_rdf.shapes_graph_to_ntriples(sg: ShapesGraph) str
Convert a ShapesGraph to N-Triples string.
- hydra.rdf.shacl_rdf.shapes_graph_to_triples(sg: ShapesGraph) Sequence[Triple]
Convert a ShapesGraph to RDF triples.
- hydra.rdf.shacl_rdf.triple_i_i_i(s: Iri, p: Iri, o: Iri) Triple
Create a triple from IRI subject, IRI predicate, and IRI object.
- hydra.rdf.shacl_rdf.triple_i_i_n(s: Iri, p: Iri, o: Node_) Triple
Create a triple from IRI subject, IRI predicate, and node object.
- hydra.rdf.shacl_rdf.triple_r_i_i(s: Resource, p: Iri, o: Iri) Triple
Create a triple from resource subject, IRI predicate, and IRI object.
- hydra.rdf.shacl_rdf.triple_r_i_n(s: Resource, p: Iri, o: Node_) Triple
Create a triple from resource subject, IRI predicate, and node object.
- hydra.rdf.shacl_rdf.triple_to_description(t: Triple) Description
Convert a single triple to a description (one triple per description).