FunctionalDataProperty
- class FunctionalDataProperty(data_property_expression: DataPropertyExpression | URIRef | Reference | Referenced | str | IdentifierBox, *, annotations: list[Annotation] | None = None)[source]
Bases:
DataPropertyAxiom
A data property axiom for 9.3.6 “Functional Data Properties”.
Consider the ontology consisting of the following axioms.
>>> FunctionalDataProperty("a:hasAge") # Each object can have at most one age. >>> DataPropertyAssertion("a:hasAge", "a:Meg", 17) # Meg is seventeen years old.
By the first axiom,
a:hasAge
can point froma:Meg
to at most one distinct literal. In this example ontology, this axiom is satisfied. If, however, the ontology were extended with the following assertion, the semantics of functionality axioms would imply that"15"^^xsd:integer
is equal to"17"^^xsd:integer
, which is a contradiction and the ontology would become inconsistent:>>> DataPropertyAssertion("a:hasAge", "a:Meg", 15)
Instantiate a functional data property axiom.
Methods Summary
to_rdflib_node
(graph, converter)Represent the functional data property for RDF.
Methods Documentation